configure 897 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921129221292312924129251292612927129281292912930129311293212933129341293512936129371293812939129401294112942129431294412945129461294712948129491295012951129521295312954129551295612957129581295912960129611296212963129641296512966129671296812969129701297112972129731297412975129761297712978129791298012981129821298312984129851298612987129881298912990129911299212993129941299512996129971299812999130001300113002130031300413005130061300713008130091301013011130121301313014130151301613017130181301913020130211302213023130241302513026130271302813029130301303113032130331303413035130361303713038130391304013041130421304313044130451304613047130481304913050130511305213053130541305513056130571305813059130601306113062130631306413065130661306713068130691307013071130721307313074130751307613077130781307913080130811308213083130841308513086130871308813089130901309113092130931309413095130961309713098130991310013101131021310313104131051310613107131081310913110131111311213113131141311513116131171311813119131201312113122131231312413125131261312713128131291313013131131321313313134131351313613137131381313913140131411314213143131441314513146131471314813149131501315113152131531315413155131561315713158131591316013161131621316313164131651316613167131681316913170131711317213173131741317513176131771317813179131801318113182131831318413185131861318713188131891319013191131921319313194131951319613197131981319913200132011320213203132041320513206132071320813209132101321113212132131321413215132161321713218132191322013221132221322313224132251322613227132281322913230132311323213233132341323513236132371323813239132401324113242132431324413245132461324713248132491325013251132521325313254132551325613257132581325913260132611326213263132641326513266132671326813269132701327113272132731327413275132761327713278132791328013281132821328313284132851328613287132881328913290132911329213293132941329513296132971329813299133001330113302133031330413305133061330713308133091331013311133121331313314133151331613317133181331913320133211332213323133241332513326133271332813329133301333113332133331333413335133361333713338133391334013341133421334313344133451334613347133481334913350133511335213353133541335513356133571335813359133601336113362133631336413365133661336713368133691337013371133721337313374133751337613377133781337913380133811338213383133841338513386133871338813389133901339113392133931339413395133961339713398133991340013401134021340313404134051340613407134081340913410134111341213413134141341513416134171341813419134201342113422134231342413425134261342713428134291343013431134321343313434134351343613437134381343913440134411344213443134441344513446134471344813449134501345113452134531345413455134561345713458134591346013461134621346313464134651346613467134681346913470134711347213473134741347513476134771347813479134801348113482134831348413485134861348713488134891349013491134921349313494134951349613497134981349913500135011350213503135041350513506135071350813509135101351113512135131351413515135161351713518135191352013521135221352313524135251352613527135281352913530135311353213533135341353513536135371353813539135401354113542135431354413545135461354713548135491355013551135521355313554135551355613557135581355913560135611356213563135641356513566135671356813569135701357113572135731357413575135761357713578135791358013581135821358313584135851358613587135881358913590135911359213593135941359513596135971359813599136001360113602136031360413605136061360713608136091361013611136121361313614136151361613617136181361913620136211362213623136241362513626136271362813629136301363113632136331363413635136361363713638136391364013641136421364313644136451364613647136481364913650136511365213653136541365513656136571365813659136601366113662136631366413665136661366713668136691367013671136721367313674136751367613677136781367913680136811368213683136841368513686136871368813689136901369113692136931369413695136961369713698136991370013701137021370313704137051370613707137081370913710137111371213713137141371513716137171371813719137201372113722137231372413725137261372713728137291373013731137321373313734137351373613737137381373913740137411374213743137441374513746137471374813749137501375113752137531375413755137561375713758137591376013761137621376313764137651376613767137681376913770137711377213773137741377513776137771377813779137801378113782137831378413785137861378713788137891379013791137921379313794137951379613797137981379913800138011380213803138041380513806138071380813809138101381113812138131381413815138161381713818138191382013821138221382313824138251382613827138281382913830138311383213833138341383513836138371383813839138401384113842138431384413845138461384713848138491385013851138521385313854138551385613857138581385913860138611386213863138641386513866138671386813869138701387113872138731387413875138761387713878138791388013881138821388313884138851388613887138881388913890138911389213893138941389513896138971389813899139001390113902139031390413905139061390713908139091391013911139121391313914139151391613917139181391913920139211392213923139241392513926139271392813929139301393113932139331393413935139361393713938139391394013941139421394313944139451394613947139481394913950139511395213953139541395513956139571395813959139601396113962139631396413965139661396713968139691397013971139721397313974139751397613977139781397913980139811398213983139841398513986139871398813989139901399113992139931399413995139961399713998139991400014001140021400314004140051400614007140081400914010140111401214013140141401514016140171401814019140201402114022140231402414025140261402714028140291403014031140321403314034140351403614037140381403914040140411404214043140441404514046140471404814049140501405114052140531405414055140561405714058140591406014061140621406314064140651406614067140681406914070140711407214073140741407514076140771407814079140801408114082140831408414085140861408714088140891409014091140921409314094140951409614097140981409914100141011410214103141041410514106141071410814109141101411114112141131411414115141161411714118141191412014121141221412314124141251412614127141281412914130141311413214133141341413514136141371413814139141401414114142141431414414145141461414714148141491415014151141521415314154141551415614157141581415914160141611416214163141641416514166141671416814169141701417114172141731417414175141761417714178141791418014181141821418314184141851418614187141881418914190141911419214193141941419514196141971419814199142001420114202142031420414205142061420714208142091421014211142121421314214142151421614217142181421914220142211422214223142241422514226142271422814229142301423114232142331423414235142361423714238142391424014241142421424314244142451424614247142481424914250142511425214253142541425514256142571425814259142601426114262142631426414265142661426714268142691427014271142721427314274142751427614277142781427914280142811428214283142841428514286142871428814289142901429114292142931429414295142961429714298142991430014301143021430314304143051430614307143081430914310143111431214313143141431514316143171431814319143201432114322143231432414325143261432714328143291433014331143321433314334143351433614337143381433914340143411434214343143441434514346143471434814349143501435114352143531435414355143561435714358143591436014361143621436314364143651436614367143681436914370143711437214373143741437514376143771437814379143801438114382143831438414385143861438714388143891439014391143921439314394143951439614397143981439914400144011440214403144041440514406144071440814409144101441114412144131441414415144161441714418144191442014421144221442314424144251442614427144281442914430144311443214433144341443514436144371443814439144401444114442144431444414445144461444714448144491445014451144521445314454144551445614457144581445914460144611446214463144641446514466144671446814469144701447114472144731447414475144761447714478144791448014481144821448314484144851448614487144881448914490144911449214493144941449514496144971449814499145001450114502145031450414505145061450714508145091451014511145121451314514145151451614517145181451914520145211452214523145241452514526145271452814529145301453114532145331453414535145361453714538145391454014541145421454314544145451454614547145481454914550145511455214553145541455514556145571455814559145601456114562145631456414565145661456714568145691457014571145721457314574145751457614577145781457914580145811458214583145841458514586145871458814589145901459114592145931459414595145961459714598145991460014601146021460314604146051460614607146081460914610146111461214613146141461514616146171461814619146201462114622146231462414625146261462714628146291463014631146321463314634146351463614637146381463914640146411464214643146441464514646146471464814649146501465114652146531465414655146561465714658146591466014661146621466314664146651466614667146681466914670146711467214673146741467514676146771467814679146801468114682146831468414685146861468714688146891469014691146921469314694146951469614697146981469914700147011470214703147041470514706147071470814709147101471114712147131471414715147161471714718147191472014721147221472314724147251472614727147281472914730147311473214733147341473514736147371473814739147401474114742147431474414745147461474714748147491475014751147521475314754147551475614757147581475914760147611476214763147641476514766147671476814769147701477114772147731477414775147761477714778147791478014781147821478314784147851478614787147881478914790147911479214793147941479514796147971479814799148001480114802148031480414805148061480714808148091481014811148121481314814148151481614817148181481914820148211482214823148241482514826148271482814829148301483114832148331483414835148361483714838148391484014841148421484314844148451484614847148481484914850148511485214853148541485514856148571485814859148601486114862148631486414865148661486714868148691487014871148721487314874148751487614877148781487914880148811488214883148841488514886148871488814889148901489114892148931489414895148961489714898148991490014901149021490314904149051490614907149081490914910149111491214913149141491514916149171491814919149201492114922149231492414925149261492714928149291493014931149321493314934149351493614937149381493914940149411494214943149441494514946149471494814949149501495114952149531495414955149561495714958149591496014961149621496314964149651496614967149681496914970149711497214973149741497514976149771497814979149801498114982149831498414985149861498714988149891499014991149921499314994149951499614997149981499915000150011500215003150041500515006150071500815009150101501115012150131501415015150161501715018150191502015021150221502315024150251502615027150281502915030150311503215033150341503515036150371503815039150401504115042150431504415045150461504715048150491505015051150521505315054150551505615057150581505915060150611506215063150641506515066150671506815069150701507115072150731507415075150761507715078150791508015081150821508315084150851508615087150881508915090150911509215093150941509515096150971509815099151001510115102151031510415105151061510715108151091511015111151121511315114151151511615117151181511915120151211512215123151241512515126151271512815129151301513115132151331513415135151361513715138151391514015141151421514315144151451514615147151481514915150151511515215153151541515515156151571515815159151601516115162151631516415165151661516715168151691517015171151721517315174151751517615177151781517915180151811518215183151841518515186151871518815189151901519115192151931519415195151961519715198151991520015201152021520315204152051520615207152081520915210152111521215213152141521515216152171521815219152201522115222152231522415225152261522715228152291523015231152321523315234152351523615237152381523915240152411524215243152441524515246152471524815249152501525115252152531525415255152561525715258152591526015261152621526315264152651526615267152681526915270152711527215273152741527515276152771527815279152801528115282152831528415285152861528715288152891529015291152921529315294152951529615297152981529915300153011530215303153041530515306153071530815309153101531115312153131531415315153161531715318153191532015321153221532315324153251532615327153281532915330153311533215333153341533515336153371533815339153401534115342153431534415345153461534715348153491535015351153521535315354153551535615357153581535915360153611536215363153641536515366153671536815369153701537115372153731537415375153761537715378153791538015381153821538315384153851538615387153881538915390153911539215393153941539515396153971539815399154001540115402154031540415405154061540715408154091541015411154121541315414154151541615417154181541915420154211542215423154241542515426154271542815429154301543115432154331543415435154361543715438154391544015441154421544315444154451544615447154481544915450154511545215453154541545515456154571545815459154601546115462154631546415465154661546715468154691547015471154721547315474154751547615477154781547915480154811548215483154841548515486154871548815489154901549115492154931549415495154961549715498154991550015501155021550315504155051550615507155081550915510155111551215513155141551515516155171551815519155201552115522155231552415525155261552715528155291553015531155321553315534155351553615537155381553915540155411554215543155441554515546155471554815549155501555115552155531555415555155561555715558155591556015561155621556315564155651556615567155681556915570155711557215573155741557515576155771557815579155801558115582155831558415585155861558715588155891559015591155921559315594155951559615597155981559915600156011560215603156041560515606156071560815609156101561115612156131561415615156161561715618156191562015621156221562315624156251562615627156281562915630156311563215633156341563515636156371563815639156401564115642156431564415645156461564715648156491565015651156521565315654156551565615657156581565915660156611566215663156641566515666156671566815669156701567115672156731567415675156761567715678156791568015681156821568315684156851568615687156881568915690156911569215693156941569515696156971569815699157001570115702157031570415705157061570715708157091571015711157121571315714157151571615717157181571915720157211572215723157241572515726157271572815729157301573115732157331573415735157361573715738157391574015741157421574315744157451574615747157481574915750157511575215753157541575515756157571575815759157601576115762157631576415765157661576715768157691577015771157721577315774157751577615777157781577915780157811578215783157841578515786157871578815789157901579115792157931579415795157961579715798157991580015801158021580315804158051580615807158081580915810158111581215813158141581515816158171581815819158201582115822158231582415825158261582715828158291583015831158321583315834158351583615837158381583915840158411584215843158441584515846158471584815849158501585115852158531585415855158561585715858158591586015861158621586315864158651586615867158681586915870158711587215873158741587515876158771587815879158801588115882158831588415885158861588715888158891589015891158921589315894158951589615897158981589915900159011590215903159041590515906159071590815909159101591115912159131591415915159161591715918159191592015921159221592315924159251592615927159281592915930159311593215933159341593515936159371593815939159401594115942159431594415945159461594715948159491595015951159521595315954159551595615957159581595915960159611596215963159641596515966159671596815969159701597115972159731597415975159761597715978159791598015981159821598315984159851598615987159881598915990159911599215993159941599515996159971599815999160001600116002160031600416005160061600716008160091601016011160121601316014160151601616017160181601916020160211602216023160241602516026160271602816029160301603116032160331603416035160361603716038160391604016041160421604316044160451604616047160481604916050160511605216053160541605516056160571605816059160601606116062160631606416065160661606716068160691607016071160721607316074160751607616077160781607916080160811608216083160841608516086160871608816089160901609116092160931609416095160961609716098160991610016101161021610316104161051610616107161081610916110161111611216113161141611516116161171611816119161201612116122161231612416125161261612716128161291613016131161321613316134161351613616137161381613916140161411614216143161441614516146161471614816149161501615116152161531615416155161561615716158161591616016161161621616316164161651616616167161681616916170161711617216173161741617516176161771617816179161801618116182161831618416185161861618716188161891619016191161921619316194161951619616197161981619916200162011620216203162041620516206162071620816209162101621116212162131621416215162161621716218162191622016221162221622316224162251622616227162281622916230162311623216233162341623516236162371623816239162401624116242162431624416245162461624716248162491625016251162521625316254162551625616257162581625916260162611626216263162641626516266162671626816269162701627116272162731627416275162761627716278162791628016281162821628316284162851628616287162881628916290162911629216293162941629516296162971629816299163001630116302163031630416305163061630716308163091631016311163121631316314163151631616317163181631916320163211632216323163241632516326163271632816329163301633116332163331633416335163361633716338163391634016341163421634316344163451634616347163481634916350163511635216353163541635516356163571635816359163601636116362163631636416365163661636716368163691637016371163721637316374163751637616377163781637916380163811638216383163841638516386163871638816389163901639116392163931639416395163961639716398163991640016401164021640316404164051640616407164081640916410164111641216413164141641516416164171641816419164201642116422164231642416425164261642716428164291643016431164321643316434164351643616437164381643916440164411644216443164441644516446164471644816449164501645116452164531645416455164561645716458164591646016461164621646316464164651646616467164681646916470164711647216473164741647516476164771647816479164801648116482164831648416485164861648716488164891649016491164921649316494164951649616497164981649916500165011650216503165041650516506165071650816509165101651116512165131651416515165161651716518165191652016521165221652316524165251652616527165281652916530165311653216533165341653516536165371653816539165401654116542165431654416545165461654716548165491655016551165521655316554165551655616557165581655916560165611656216563165641656516566165671656816569165701657116572165731657416575165761657716578165791658016581165821658316584165851658616587165881658916590165911659216593165941659516596165971659816599166001660116602166031660416605166061660716608166091661016611166121661316614166151661616617166181661916620166211662216623166241662516626166271662816629166301663116632166331663416635166361663716638166391664016641166421664316644166451664616647166481664916650166511665216653166541665516656166571665816659166601666116662166631666416665166661666716668166691667016671166721667316674166751667616677166781667916680166811668216683166841668516686166871668816689166901669116692166931669416695166961669716698166991670016701167021670316704167051670616707167081670916710167111671216713167141671516716167171671816719167201672116722167231672416725167261672716728167291673016731167321673316734167351673616737167381673916740167411674216743167441674516746167471674816749167501675116752167531675416755167561675716758167591676016761167621676316764167651676616767167681676916770167711677216773167741677516776167771677816779167801678116782167831678416785167861678716788167891679016791167921679316794167951679616797167981679916800168011680216803168041680516806168071680816809168101681116812168131681416815168161681716818168191682016821168221682316824168251682616827168281682916830168311683216833168341683516836168371683816839168401684116842168431684416845168461684716848168491685016851168521685316854168551685616857168581685916860168611686216863168641686516866168671686816869168701687116872168731687416875168761687716878168791688016881168821688316884168851688616887168881688916890168911689216893168941689516896168971689816899169001690116902169031690416905169061690716908169091691016911169121691316914169151691616917169181691916920169211692216923169241692516926169271692816929169301693116932169331693416935169361693716938169391694016941169421694316944169451694616947169481694916950169511695216953169541695516956169571695816959169601696116962169631696416965169661696716968169691697016971169721697316974169751697616977169781697916980169811698216983169841698516986169871698816989169901699116992169931699416995169961699716998169991700017001170021700317004170051700617007170081700917010170111701217013170141701517016170171701817019170201702117022170231702417025170261702717028170291703017031170321703317034170351703617037170381703917040170411704217043170441704517046170471704817049170501705117052170531705417055170561705717058170591706017061170621706317064170651706617067170681706917070170711707217073170741707517076170771707817079170801708117082170831708417085170861708717088170891709017091170921709317094170951709617097170981709917100171011710217103171041710517106171071710817109171101711117112171131711417115171161711717118171191712017121171221712317124171251712617127171281712917130171311713217133171341713517136171371713817139171401714117142171431714417145171461714717148171491715017151171521715317154171551715617157171581715917160171611716217163171641716517166171671716817169171701717117172171731717417175171761717717178171791718017181171821718317184171851718617187171881718917190171911719217193171941719517196171971719817199172001720117202172031720417205172061720717208172091721017211172121721317214172151721617217172181721917220172211722217223172241722517226172271722817229172301723117232172331723417235172361723717238172391724017241172421724317244172451724617247172481724917250172511725217253172541725517256172571725817259172601726117262172631726417265172661726717268172691727017271172721727317274172751727617277172781727917280172811728217283172841728517286172871728817289172901729117292172931729417295172961729717298172991730017301173021730317304173051730617307173081730917310173111731217313173141731517316173171731817319173201732117322173231732417325173261732717328173291733017331173321733317334173351733617337173381733917340173411734217343173441734517346173471734817349173501735117352173531735417355173561735717358173591736017361173621736317364173651736617367173681736917370173711737217373173741737517376173771737817379173801738117382173831738417385173861738717388173891739017391173921739317394173951739617397173981739917400174011740217403174041740517406174071740817409174101741117412174131741417415174161741717418174191742017421174221742317424174251742617427174281742917430174311743217433174341743517436174371743817439174401744117442174431744417445174461744717448174491745017451174521745317454174551745617457174581745917460174611746217463174641746517466174671746817469174701747117472174731747417475174761747717478174791748017481174821748317484174851748617487174881748917490174911749217493174941749517496174971749817499175001750117502175031750417505175061750717508175091751017511175121751317514175151751617517175181751917520175211752217523175241752517526175271752817529175301753117532175331753417535175361753717538175391754017541175421754317544175451754617547175481754917550175511755217553175541755517556175571755817559175601756117562175631756417565175661756717568175691757017571175721757317574175751757617577175781757917580175811758217583175841758517586175871758817589175901759117592175931759417595175961759717598175991760017601176021760317604176051760617607176081760917610176111761217613176141761517616176171761817619176201762117622176231762417625176261762717628176291763017631176321763317634176351763617637176381763917640176411764217643176441764517646176471764817649176501765117652176531765417655176561765717658176591766017661176621766317664176651766617667176681766917670176711767217673176741767517676176771767817679176801768117682176831768417685176861768717688176891769017691176921769317694176951769617697176981769917700177011770217703177041770517706177071770817709177101771117712177131771417715177161771717718177191772017721177221772317724177251772617727177281772917730177311773217733177341773517736177371773817739177401774117742177431774417745177461774717748177491775017751177521775317754177551775617757177581775917760177611776217763177641776517766177671776817769177701777117772177731777417775177761777717778177791778017781177821778317784177851778617787177881778917790177911779217793177941779517796177971779817799178001780117802178031780417805178061780717808178091781017811178121781317814178151781617817178181781917820178211782217823178241782517826178271782817829178301783117832178331783417835178361783717838178391784017841178421784317844178451784617847178481784917850178511785217853178541785517856178571785817859178601786117862178631786417865178661786717868178691787017871178721787317874178751787617877178781787917880178811788217883178841788517886178871788817889178901789117892178931789417895178961789717898178991790017901179021790317904179051790617907179081790917910179111791217913179141791517916179171791817919179201792117922179231792417925179261792717928179291793017931179321793317934179351793617937179381793917940179411794217943179441794517946179471794817949179501795117952179531795417955179561795717958179591796017961179621796317964179651796617967179681796917970179711797217973179741797517976179771797817979179801798117982179831798417985179861798717988179891799017991179921799317994179951799617997179981799918000180011800218003180041800518006180071800818009180101801118012180131801418015180161801718018180191802018021180221802318024180251802618027180281802918030180311803218033180341803518036180371803818039180401804118042180431804418045180461804718048180491805018051180521805318054180551805618057180581805918060180611806218063180641806518066180671806818069180701807118072180731807418075180761807718078180791808018081180821808318084180851808618087180881808918090180911809218093180941809518096180971809818099181001810118102181031810418105181061810718108181091811018111181121811318114181151811618117181181811918120181211812218123181241812518126181271812818129181301813118132181331813418135181361813718138181391814018141181421814318144181451814618147181481814918150181511815218153181541815518156181571815818159181601816118162181631816418165181661816718168181691817018171181721817318174181751817618177181781817918180181811818218183181841818518186181871818818189181901819118192181931819418195181961819718198181991820018201182021820318204182051820618207182081820918210182111821218213182141821518216182171821818219182201822118222182231822418225182261822718228182291823018231182321823318234182351823618237182381823918240182411824218243182441824518246182471824818249182501825118252182531825418255182561825718258182591826018261182621826318264182651826618267182681826918270182711827218273182741827518276182771827818279182801828118282182831828418285182861828718288182891829018291182921829318294182951829618297182981829918300183011830218303183041830518306183071830818309183101831118312183131831418315183161831718318183191832018321183221832318324183251832618327183281832918330183311833218333183341833518336183371833818339183401834118342183431834418345183461834718348183491835018351183521835318354183551835618357183581835918360183611836218363183641836518366183671836818369183701837118372183731837418375183761837718378183791838018381183821838318384183851838618387183881838918390183911839218393183941839518396183971839818399184001840118402184031840418405184061840718408184091841018411184121841318414184151841618417184181841918420184211842218423184241842518426184271842818429184301843118432184331843418435184361843718438184391844018441184421844318444184451844618447184481844918450184511845218453184541845518456184571845818459184601846118462184631846418465184661846718468184691847018471184721847318474184751847618477184781847918480184811848218483184841848518486184871848818489184901849118492184931849418495184961849718498184991850018501185021850318504185051850618507185081850918510185111851218513185141851518516185171851818519185201852118522185231852418525185261852718528185291853018531185321853318534185351853618537185381853918540185411854218543185441854518546185471854818549185501855118552185531855418555185561855718558185591856018561185621856318564185651856618567185681856918570185711857218573185741857518576185771857818579185801858118582185831858418585185861858718588185891859018591185921859318594185951859618597185981859918600186011860218603186041860518606186071860818609186101861118612186131861418615186161861718618186191862018621186221862318624186251862618627186281862918630186311863218633186341863518636186371863818639186401864118642186431864418645186461864718648186491865018651186521865318654186551865618657186581865918660186611866218663186641866518666186671866818669186701867118672186731867418675186761867718678186791868018681186821868318684186851868618687186881868918690186911869218693186941869518696186971869818699187001870118702187031870418705187061870718708187091871018711187121871318714187151871618717187181871918720187211872218723187241872518726187271872818729187301873118732187331873418735187361873718738187391874018741187421874318744187451874618747187481874918750187511875218753187541875518756187571875818759187601876118762187631876418765187661876718768187691877018771187721877318774187751877618777187781877918780187811878218783187841878518786187871878818789187901879118792187931879418795187961879718798187991880018801188021880318804188051880618807188081880918810188111881218813188141881518816188171881818819188201882118822188231882418825188261882718828188291883018831188321883318834188351883618837188381883918840188411884218843188441884518846188471884818849188501885118852188531885418855188561885718858188591886018861188621886318864188651886618867188681886918870188711887218873188741887518876188771887818879188801888118882188831888418885188861888718888188891889018891188921889318894188951889618897188981889918900189011890218903189041890518906189071890818909189101891118912189131891418915189161891718918189191892018921189221892318924189251892618927189281892918930189311893218933189341893518936189371893818939189401894118942189431894418945189461894718948189491895018951189521895318954189551895618957189581895918960189611896218963189641896518966189671896818969189701897118972189731897418975189761897718978189791898018981189821898318984189851898618987189881898918990189911899218993189941899518996189971899818999190001900119002190031900419005190061900719008190091901019011190121901319014190151901619017190181901919020190211902219023190241902519026190271902819029190301903119032190331903419035190361903719038190391904019041190421904319044190451904619047190481904919050190511905219053190541905519056190571905819059190601906119062190631906419065190661906719068190691907019071190721907319074190751907619077190781907919080190811908219083190841908519086190871908819089190901909119092190931909419095190961909719098190991910019101191021910319104191051910619107191081910919110191111911219113191141911519116191171911819119191201912119122191231912419125191261912719128191291913019131191321913319134191351913619137191381913919140191411914219143191441914519146191471914819149191501915119152191531915419155191561915719158191591916019161191621916319164191651916619167191681916919170191711917219173191741917519176191771917819179191801918119182191831918419185191861918719188191891919019191191921919319194191951919619197191981919919200192011920219203192041920519206192071920819209192101921119212192131921419215192161921719218192191922019221192221922319224192251922619227192281922919230192311923219233192341923519236192371923819239192401924119242192431924419245192461924719248192491925019251192521925319254192551925619257192581925919260192611926219263192641926519266192671926819269192701927119272192731927419275192761927719278192791928019281192821928319284192851928619287192881928919290192911929219293192941929519296192971929819299193001930119302193031930419305193061930719308193091931019311193121931319314193151931619317193181931919320193211932219323193241932519326193271932819329193301933119332193331933419335193361933719338193391934019341193421934319344193451934619347193481934919350193511935219353193541935519356193571935819359193601936119362193631936419365193661936719368193691937019371193721937319374193751937619377193781937919380193811938219383193841938519386193871938819389193901939119392193931939419395193961939719398193991940019401194021940319404194051940619407194081940919410194111941219413194141941519416194171941819419194201942119422194231942419425194261942719428194291943019431194321943319434194351943619437194381943919440194411944219443194441944519446194471944819449194501945119452194531945419455194561945719458194591946019461194621946319464194651946619467194681946919470194711947219473194741947519476194771947819479194801948119482194831948419485194861948719488194891949019491194921949319494194951949619497194981949919500195011950219503195041950519506195071950819509195101951119512195131951419515195161951719518195191952019521195221952319524195251952619527195281952919530195311953219533195341953519536195371953819539195401954119542195431954419545195461954719548195491955019551195521955319554195551955619557195581955919560195611956219563195641956519566195671956819569195701957119572195731957419575195761957719578195791958019581195821958319584195851958619587195881958919590195911959219593195941959519596195971959819599196001960119602196031960419605196061960719608196091961019611196121961319614196151961619617196181961919620196211962219623196241962519626196271962819629196301963119632196331963419635196361963719638196391964019641196421964319644196451964619647196481964919650196511965219653196541965519656196571965819659196601966119662196631966419665196661966719668196691967019671196721967319674196751967619677196781967919680196811968219683196841968519686196871968819689196901969119692196931969419695196961969719698196991970019701197021970319704197051970619707197081970919710197111971219713197141971519716197171971819719197201972119722197231972419725197261972719728197291973019731197321973319734197351973619737197381973919740197411974219743197441974519746197471974819749197501975119752197531975419755197561975719758197591976019761197621976319764197651976619767197681976919770197711977219773197741977519776197771977819779197801978119782197831978419785197861978719788197891979019791197921979319794197951979619797197981979919800198011980219803198041980519806198071980819809198101981119812198131981419815198161981719818198191982019821198221982319824198251982619827198281982919830198311983219833198341983519836198371983819839198401984119842198431984419845198461984719848198491985019851198521985319854198551985619857198581985919860198611986219863198641986519866198671986819869198701987119872198731987419875198761987719878198791988019881198821988319884198851988619887198881988919890198911989219893198941989519896198971989819899199001990119902199031990419905199061990719908199091991019911199121991319914199151991619917199181991919920199211992219923199241992519926199271992819929199301993119932199331993419935199361993719938199391994019941199421994319944199451994619947199481994919950199511995219953199541995519956199571995819959199601996119962199631996419965199661996719968199691997019971199721997319974199751997619977199781997919980199811998219983199841998519986199871998819989199901999119992199931999419995199961999719998199992000020001200022000320004200052000620007200082000920010200112001220013200142001520016200172001820019200202002120022200232002420025200262002720028200292003020031200322003320034200352003620037200382003920040200412004220043200442004520046200472004820049200502005120052200532005420055200562005720058200592006020061200622006320064200652006620067200682006920070200712007220073200742007520076200772007820079200802008120082200832008420085200862008720088200892009020091200922009320094200952009620097200982009920100201012010220103201042010520106201072010820109201102011120112201132011420115201162011720118201192012020121201222012320124201252012620127201282012920130201312013220133201342013520136201372013820139201402014120142201432014420145201462014720148201492015020151201522015320154201552015620157201582015920160201612016220163201642016520166201672016820169201702017120172201732017420175201762017720178201792018020181201822018320184201852018620187201882018920190201912019220193201942019520196201972019820199202002020120202202032020420205202062020720208202092021020211202122021320214202152021620217202182021920220202212022220223202242022520226202272022820229202302023120232202332023420235202362023720238202392024020241202422024320244202452024620247202482024920250202512025220253202542025520256202572025820259202602026120262202632026420265202662026720268202692027020271202722027320274202752027620277202782027920280202812028220283202842028520286202872028820289202902029120292202932029420295202962029720298202992030020301203022030320304203052030620307203082030920310203112031220313203142031520316203172031820319203202032120322203232032420325203262032720328203292033020331203322033320334203352033620337203382033920340203412034220343203442034520346203472034820349203502035120352203532035420355203562035720358203592036020361203622036320364203652036620367203682036920370203712037220373203742037520376203772037820379203802038120382203832038420385203862038720388203892039020391203922039320394203952039620397203982039920400204012040220403204042040520406204072040820409204102041120412204132041420415204162041720418204192042020421204222042320424204252042620427204282042920430204312043220433204342043520436204372043820439204402044120442204432044420445204462044720448204492045020451204522045320454204552045620457204582045920460204612046220463204642046520466204672046820469204702047120472204732047420475204762047720478204792048020481204822048320484204852048620487204882048920490204912049220493204942049520496204972049820499205002050120502205032050420505205062050720508205092051020511205122051320514205152051620517205182051920520205212052220523205242052520526205272052820529205302053120532205332053420535205362053720538205392054020541205422054320544205452054620547205482054920550205512055220553205542055520556205572055820559205602056120562205632056420565205662056720568205692057020571205722057320574205752057620577205782057920580205812058220583205842058520586205872058820589205902059120592205932059420595205962059720598205992060020601206022060320604206052060620607206082060920610206112061220613206142061520616206172061820619206202062120622206232062420625206262062720628206292063020631206322063320634206352063620637206382063920640206412064220643206442064520646206472064820649206502065120652206532065420655206562065720658206592066020661206622066320664206652066620667206682066920670206712067220673206742067520676206772067820679206802068120682206832068420685206862068720688206892069020691206922069320694206952069620697206982069920700207012070220703207042070520706207072070820709207102071120712207132071420715207162071720718207192072020721207222072320724207252072620727207282072920730207312073220733207342073520736207372073820739207402074120742207432074420745207462074720748207492075020751207522075320754207552075620757207582075920760207612076220763207642076520766207672076820769207702077120772207732077420775207762077720778207792078020781207822078320784207852078620787207882078920790207912079220793207942079520796207972079820799208002080120802208032080420805208062080720808208092081020811208122081320814208152081620817208182081920820208212082220823208242082520826208272082820829208302083120832208332083420835208362083720838208392084020841208422084320844208452084620847208482084920850208512085220853208542085520856208572085820859208602086120862208632086420865208662086720868208692087020871208722087320874208752087620877208782087920880208812088220883208842088520886208872088820889208902089120892208932089420895208962089720898208992090020901209022090320904209052090620907209082090920910209112091220913209142091520916209172091820919209202092120922209232092420925209262092720928209292093020931209322093320934209352093620937209382093920940209412094220943209442094520946209472094820949209502095120952209532095420955209562095720958209592096020961209622096320964209652096620967209682096920970209712097220973209742097520976209772097820979209802098120982209832098420985209862098720988209892099020991209922099320994209952099620997209982099921000210012100221003210042100521006210072100821009210102101121012210132101421015210162101721018210192102021021210222102321024210252102621027210282102921030210312103221033210342103521036210372103821039210402104121042210432104421045210462104721048210492105021051210522105321054210552105621057210582105921060210612106221063210642106521066210672106821069210702107121072210732107421075210762107721078210792108021081210822108321084210852108621087210882108921090210912109221093210942109521096210972109821099211002110121102211032110421105211062110721108211092111021111211122111321114211152111621117211182111921120211212112221123211242112521126211272112821129211302113121132211332113421135211362113721138211392114021141211422114321144211452114621147211482114921150211512115221153211542115521156211572115821159211602116121162211632116421165211662116721168211692117021171211722117321174211752117621177211782117921180211812118221183211842118521186211872118821189211902119121192211932119421195211962119721198211992120021201212022120321204212052120621207212082120921210212112121221213212142121521216212172121821219212202122121222212232122421225212262122721228212292123021231212322123321234212352123621237212382123921240212412124221243212442124521246212472124821249212502125121252212532125421255212562125721258212592126021261212622126321264212652126621267212682126921270212712127221273212742127521276212772127821279212802128121282212832128421285212862128721288212892129021291212922129321294212952129621297212982129921300213012130221303213042130521306213072130821309213102131121312213132131421315213162131721318213192132021321213222132321324213252132621327213282132921330213312133221333213342133521336213372133821339213402134121342213432134421345213462134721348213492135021351213522135321354213552135621357213582135921360213612136221363213642136521366213672136821369213702137121372213732137421375213762137721378213792138021381213822138321384213852138621387213882138921390213912139221393213942139521396213972139821399214002140121402214032140421405214062140721408214092141021411214122141321414214152141621417214182141921420214212142221423214242142521426214272142821429214302143121432214332143421435214362143721438214392144021441214422144321444214452144621447214482144921450214512145221453214542145521456214572145821459214602146121462214632146421465214662146721468214692147021471214722147321474214752147621477214782147921480214812148221483214842148521486214872148821489214902149121492214932149421495214962149721498214992150021501215022150321504215052150621507215082150921510215112151221513215142151521516215172151821519215202152121522215232152421525215262152721528215292153021531215322153321534215352153621537215382153921540215412154221543215442154521546215472154821549215502155121552215532155421555215562155721558215592156021561215622156321564215652156621567215682156921570215712157221573215742157521576215772157821579215802158121582215832158421585215862158721588215892159021591215922159321594215952159621597215982159921600216012160221603216042160521606216072160821609216102161121612216132161421615216162161721618216192162021621216222162321624216252162621627216282162921630216312163221633216342163521636216372163821639216402164121642216432164421645216462164721648216492165021651216522165321654216552165621657216582165921660216612166221663216642166521666216672166821669216702167121672216732167421675216762167721678216792168021681216822168321684216852168621687216882168921690216912169221693216942169521696216972169821699217002170121702217032170421705217062170721708217092171021711217122171321714217152171621717217182171921720217212172221723217242172521726217272172821729217302173121732217332173421735217362173721738217392174021741217422174321744217452174621747217482174921750217512175221753217542175521756217572175821759217602176121762217632176421765217662176721768217692177021771217722177321774217752177621777217782177921780217812178221783217842178521786217872178821789217902179121792217932179421795217962179721798217992180021801218022180321804218052180621807218082180921810218112181221813218142181521816218172181821819218202182121822218232182421825218262182721828218292183021831218322183321834218352183621837218382183921840218412184221843218442184521846218472184821849218502185121852218532185421855218562185721858218592186021861218622186321864218652186621867218682186921870218712187221873218742187521876218772187821879218802188121882218832188421885218862188721888218892189021891218922189321894218952189621897218982189921900219012190221903219042190521906219072190821909219102191121912219132191421915219162191721918219192192021921219222192321924219252192621927219282192921930219312193221933219342193521936219372193821939219402194121942219432194421945219462194721948219492195021951219522195321954219552195621957219582195921960219612196221963219642196521966219672196821969219702197121972219732197421975219762197721978219792198021981219822198321984219852198621987219882198921990219912199221993219942199521996219972199821999220002200122002220032200422005220062200722008220092201022011220122201322014220152201622017220182201922020220212202222023220242202522026220272202822029220302203122032220332203422035220362203722038220392204022041220422204322044220452204622047220482204922050220512205222053220542205522056220572205822059220602206122062220632206422065220662206722068220692207022071220722207322074220752207622077220782207922080220812208222083220842208522086220872208822089220902209122092220932209422095220962209722098220992210022101221022210322104221052210622107221082210922110221112211222113221142211522116221172211822119221202212122122221232212422125221262212722128221292213022131221322213322134221352213622137221382213922140221412214222143221442214522146221472214822149221502215122152221532215422155221562215722158221592216022161221622216322164221652216622167221682216922170221712217222173221742217522176221772217822179221802218122182221832218422185221862218722188221892219022191221922219322194221952219622197221982219922200222012220222203222042220522206222072220822209222102221122212222132221422215222162221722218222192222022221222222222322224222252222622227222282222922230222312223222233222342223522236222372223822239222402224122242222432224422245222462224722248222492225022251222522225322254222552225622257222582225922260222612226222263222642226522266222672226822269222702227122272222732227422275222762227722278222792228022281222822228322284222852228622287222882228922290222912229222293222942229522296222972229822299223002230122302223032230422305223062230722308223092231022311223122231322314223152231622317223182231922320223212232222323223242232522326223272232822329223302233122332223332233422335223362233722338223392234022341223422234322344223452234622347223482234922350223512235222353223542235522356223572235822359223602236122362223632236422365223662236722368223692237022371223722237322374223752237622377223782237922380223812238222383223842238522386223872238822389223902239122392223932239422395223962239722398223992240022401224022240322404224052240622407224082240922410224112241222413224142241522416224172241822419224202242122422224232242422425224262242722428224292243022431224322243322434224352243622437224382243922440224412244222443224442244522446224472244822449224502245122452224532245422455224562245722458224592246022461224622246322464224652246622467224682246922470224712247222473224742247522476224772247822479224802248122482224832248422485224862248722488224892249022491224922249322494224952249622497224982249922500225012250222503225042250522506225072250822509225102251122512225132251422515225162251722518225192252022521225222252322524225252252622527225282252922530225312253222533225342253522536225372253822539225402254122542225432254422545225462254722548225492255022551225522255322554225552255622557225582255922560225612256222563225642256522566225672256822569225702257122572225732257422575225762257722578225792258022581225822258322584225852258622587225882258922590225912259222593225942259522596225972259822599226002260122602226032260422605226062260722608226092261022611226122261322614226152261622617226182261922620226212262222623226242262522626226272262822629226302263122632226332263422635226362263722638226392264022641226422264322644226452264622647226482264922650226512265222653226542265522656226572265822659226602266122662226632266422665226662266722668226692267022671226722267322674226752267622677226782267922680226812268222683226842268522686226872268822689226902269122692226932269422695226962269722698226992270022701227022270322704227052270622707227082270922710227112271222713227142271522716227172271822719227202272122722227232272422725227262272722728227292273022731227322273322734227352273622737227382273922740227412274222743227442274522746227472274822749227502275122752227532275422755227562275722758227592276022761227622276322764227652276622767227682276922770227712277222773227742277522776227772277822779227802278122782227832278422785227862278722788227892279022791227922279322794227952279622797227982279922800228012280222803228042280522806228072280822809228102281122812228132281422815228162281722818228192282022821228222282322824228252282622827228282282922830228312283222833228342283522836228372283822839228402284122842228432284422845228462284722848228492285022851228522285322854228552285622857228582285922860228612286222863228642286522866228672286822869228702287122872228732287422875228762287722878228792288022881228822288322884228852288622887228882288922890228912289222893228942289522896228972289822899229002290122902229032290422905229062290722908229092291022911229122291322914229152291622917229182291922920229212292222923229242292522926229272292822929229302293122932229332293422935229362293722938229392294022941229422294322944229452294622947229482294922950229512295222953229542295522956229572295822959229602296122962229632296422965229662296722968229692297022971229722297322974229752297622977229782297922980229812298222983229842298522986229872298822989229902299122992229932299422995229962299722998229992300023001230022300323004230052300623007230082300923010230112301223013230142301523016230172301823019230202302123022230232302423025230262302723028230292303023031230322303323034230352303623037230382303923040230412304223043230442304523046230472304823049230502305123052230532305423055230562305723058230592306023061230622306323064230652306623067230682306923070230712307223073230742307523076230772307823079230802308123082230832308423085230862308723088230892309023091230922309323094230952309623097230982309923100231012310223103231042310523106231072310823109231102311123112231132311423115231162311723118231192312023121231222312323124231252312623127231282312923130231312313223133231342313523136231372313823139231402314123142231432314423145231462314723148231492315023151231522315323154231552315623157231582315923160231612316223163231642316523166231672316823169231702317123172231732317423175231762317723178231792318023181231822318323184231852318623187231882318923190231912319223193231942319523196231972319823199232002320123202232032320423205232062320723208232092321023211232122321323214232152321623217232182321923220232212322223223232242322523226232272322823229232302323123232232332323423235232362323723238232392324023241232422324323244232452324623247232482324923250232512325223253232542325523256232572325823259232602326123262232632326423265232662326723268232692327023271232722327323274232752327623277232782327923280232812328223283232842328523286232872328823289232902329123292232932329423295232962329723298232992330023301233022330323304233052330623307233082330923310233112331223313233142331523316233172331823319233202332123322233232332423325233262332723328233292333023331233322333323334233352333623337233382333923340233412334223343233442334523346233472334823349233502335123352233532335423355233562335723358233592336023361233622336323364233652336623367233682336923370233712337223373233742337523376233772337823379233802338123382233832338423385233862338723388233892339023391233922339323394233952339623397233982339923400234012340223403234042340523406234072340823409234102341123412234132341423415234162341723418234192342023421234222342323424234252342623427234282342923430234312343223433234342343523436234372343823439234402344123442234432344423445234462344723448234492345023451234522345323454234552345623457234582345923460234612346223463234642346523466234672346823469234702347123472234732347423475234762347723478234792348023481234822348323484234852348623487234882348923490234912349223493234942349523496234972349823499235002350123502235032350423505235062350723508235092351023511235122351323514235152351623517235182351923520235212352223523235242352523526235272352823529235302353123532235332353423535235362353723538235392354023541235422354323544235452354623547235482354923550235512355223553235542355523556235572355823559235602356123562235632356423565235662356723568235692357023571235722357323574235752357623577235782357923580235812358223583235842358523586235872358823589235902359123592235932359423595235962359723598235992360023601236022360323604236052360623607236082360923610236112361223613236142361523616236172361823619236202362123622236232362423625236262362723628236292363023631236322363323634236352363623637236382363923640236412364223643236442364523646236472364823649236502365123652236532365423655236562365723658236592366023661236622366323664236652366623667236682366923670236712367223673236742367523676236772367823679236802368123682236832368423685236862368723688236892369023691236922369323694236952369623697236982369923700237012370223703237042370523706237072370823709237102371123712237132371423715237162371723718237192372023721237222372323724237252372623727237282372923730237312373223733237342373523736237372373823739237402374123742237432374423745237462374723748237492375023751237522375323754237552375623757237582375923760237612376223763237642376523766237672376823769237702377123772237732377423775237762377723778237792378023781237822378323784237852378623787237882378923790237912379223793237942379523796237972379823799238002380123802238032380423805238062380723808238092381023811238122381323814238152381623817238182381923820238212382223823238242382523826238272382823829238302383123832238332383423835238362383723838238392384023841238422384323844238452384623847238482384923850238512385223853238542385523856238572385823859238602386123862238632386423865238662386723868238692387023871238722387323874238752387623877238782387923880238812388223883238842388523886238872388823889238902389123892238932389423895238962389723898238992390023901239022390323904239052390623907239082390923910239112391223913239142391523916239172391823919239202392123922239232392423925239262392723928239292393023931239322393323934239352393623937239382393923940239412394223943239442394523946239472394823949239502395123952239532395423955239562395723958239592396023961239622396323964239652396623967239682396923970239712397223973239742397523976239772397823979239802398123982239832398423985239862398723988239892399023991239922399323994239952399623997239982399924000240012400224003240042400524006240072400824009240102401124012240132401424015240162401724018240192402024021240222402324024240252402624027240282402924030240312403224033240342403524036240372403824039240402404124042240432404424045240462404724048240492405024051240522405324054240552405624057240582405924060240612406224063240642406524066240672406824069240702407124072240732407424075240762407724078240792408024081240822408324084240852408624087240882408924090240912409224093240942409524096240972409824099241002410124102241032410424105241062410724108241092411024111241122411324114241152411624117241182411924120241212412224123241242412524126241272412824129241302413124132241332413424135241362413724138241392414024141241422414324144241452414624147241482414924150241512415224153241542415524156241572415824159241602416124162241632416424165241662416724168241692417024171241722417324174241752417624177241782417924180241812418224183241842418524186241872418824189241902419124192241932419424195241962419724198241992420024201242022420324204242052420624207242082420924210242112421224213242142421524216242172421824219242202422124222242232422424225242262422724228242292423024231242322423324234242352423624237242382423924240242412424224243242442424524246242472424824249242502425124252242532425424255242562425724258242592426024261242622426324264242652426624267242682426924270242712427224273242742427524276242772427824279242802428124282242832428424285242862428724288242892429024291242922429324294242952429624297242982429924300243012430224303243042430524306243072430824309243102431124312243132431424315243162431724318243192432024321243222432324324243252432624327243282432924330243312433224333243342433524336243372433824339243402434124342243432434424345243462434724348243492435024351243522435324354243552435624357243582435924360243612436224363243642436524366243672436824369243702437124372243732437424375243762437724378243792438024381243822438324384243852438624387243882438924390243912439224393243942439524396243972439824399244002440124402244032440424405244062440724408244092441024411244122441324414244152441624417244182441924420244212442224423244242442524426244272442824429244302443124432244332443424435244362443724438244392444024441244422444324444244452444624447244482444924450244512445224453244542445524456244572445824459244602446124462244632446424465244662446724468244692447024471244722447324474244752447624477244782447924480244812448224483244842448524486244872448824489244902449124492244932449424495244962449724498244992450024501245022450324504245052450624507245082450924510245112451224513245142451524516245172451824519245202452124522245232452424525245262452724528245292453024531245322453324534245352453624537245382453924540245412454224543245442454524546245472454824549245502455124552245532455424555245562455724558245592456024561245622456324564245652456624567245682456924570245712457224573245742457524576245772457824579245802458124582245832458424585245862458724588245892459024591245922459324594245952459624597245982459924600246012460224603246042460524606246072460824609246102461124612246132461424615246162461724618246192462024621246222462324624246252462624627246282462924630246312463224633246342463524636246372463824639246402464124642246432464424645246462464724648246492465024651246522465324654246552465624657246582465924660246612466224663246642466524666246672466824669246702467124672246732467424675246762467724678246792468024681246822468324684246852468624687246882468924690246912469224693246942469524696246972469824699247002470124702247032470424705247062470724708247092471024711247122471324714247152471624717247182471924720247212472224723247242472524726247272472824729247302473124732247332473424735247362473724738247392474024741247422474324744247452474624747247482474924750247512475224753247542475524756247572475824759247602476124762247632476424765247662476724768247692477024771247722477324774247752477624777247782477924780247812478224783247842478524786247872478824789247902479124792247932479424795247962479724798247992480024801248022480324804248052480624807248082480924810248112481224813248142481524816248172481824819248202482124822248232482424825248262482724828248292483024831248322483324834248352483624837248382483924840248412484224843248442484524846248472484824849248502485124852248532485424855248562485724858248592486024861248622486324864248652486624867248682486924870248712487224873248742487524876248772487824879248802488124882248832488424885248862488724888248892489024891248922489324894248952489624897248982489924900249012490224903249042490524906249072490824909249102491124912249132491424915249162491724918249192492024921249222492324924249252492624927249282492924930249312493224933249342493524936249372493824939249402494124942249432494424945249462494724948249492495024951249522495324954249552495624957249582495924960249612496224963249642496524966249672496824969249702497124972249732497424975249762497724978249792498024981249822498324984249852498624987249882498924990249912499224993249942499524996249972499824999250002500125002250032500425005250062500725008250092501025011250122501325014250152501625017250182501925020250212502225023250242502525026250272502825029250302503125032250332503425035250362503725038250392504025041250422504325044250452504625047250482504925050250512505225053250542505525056250572505825059250602506125062250632506425065250662506725068250692507025071250722507325074250752507625077250782507925080250812508225083250842508525086250872508825089250902509125092250932509425095250962509725098250992510025101251022510325104251052510625107251082510925110251112511225113251142511525116251172511825119251202512125122251232512425125251262512725128251292513025131251322513325134251352513625137251382513925140251412514225143251442514525146251472514825149251502515125152251532515425155251562515725158251592516025161251622516325164251652516625167251682516925170251712517225173251742517525176251772517825179251802518125182251832518425185251862518725188251892519025191251922519325194251952519625197251982519925200252012520225203252042520525206252072520825209252102521125212252132521425215252162521725218252192522025221252222522325224252252522625227252282522925230252312523225233252342523525236252372523825239252402524125242252432524425245252462524725248252492525025251252522525325254252552525625257252582525925260252612526225263252642526525266252672526825269252702527125272252732527425275252762527725278252792528025281252822528325284252852528625287252882528925290252912529225293252942529525296252972529825299253002530125302253032530425305253062530725308253092531025311253122531325314253152531625317253182531925320253212532225323253242532525326253272532825329253302533125332253332533425335253362533725338253392534025341253422534325344253452534625347253482534925350253512535225353253542535525356253572535825359253602536125362253632536425365253662536725368253692537025371253722537325374253752537625377253782537925380253812538225383253842538525386253872538825389253902539125392253932539425395253962539725398253992540025401254022540325404254052540625407254082540925410254112541225413254142541525416254172541825419254202542125422254232542425425254262542725428254292543025431254322543325434254352543625437254382543925440254412544225443254442544525446254472544825449254502545125452254532545425455254562545725458254592546025461254622546325464254652546625467254682546925470254712547225473254742547525476254772547825479254802548125482254832548425485254862548725488254892549025491254922549325494254952549625497254982549925500255012550225503255042550525506255072550825509255102551125512255132551425515255162551725518255192552025521255222552325524255252552625527255282552925530255312553225533255342553525536255372553825539255402554125542255432554425545255462554725548255492555025551255522555325554255552555625557255582555925560255612556225563255642556525566255672556825569255702557125572255732557425575255762557725578255792558025581255822558325584255852558625587255882558925590255912559225593255942559525596255972559825599256002560125602256032560425605256062560725608256092561025611256122561325614256152561625617256182561925620256212562225623256242562525626256272562825629256302563125632256332563425635256362563725638256392564025641256422564325644256452564625647256482564925650256512565225653256542565525656256572565825659256602566125662256632566425665256662566725668256692567025671256722567325674256752567625677256782567925680256812568225683256842568525686256872568825689256902569125692256932569425695256962569725698256992570025701257022570325704257052570625707257082570925710257112571225713257142571525716257172571825719257202572125722257232572425725257262572725728257292573025731257322573325734257352573625737257382573925740257412574225743257442574525746257472574825749257502575125752257532575425755257562575725758257592576025761257622576325764257652576625767257682576925770257712577225773257742577525776257772577825779257802578125782257832578425785257862578725788257892579025791257922579325794257952579625797257982579925800258012580225803258042580525806258072580825809258102581125812258132581425815258162581725818258192582025821258222582325824258252582625827258282582925830258312583225833258342583525836258372583825839258402584125842258432584425845258462584725848258492585025851258522585325854258552585625857258582585925860258612586225863258642586525866258672586825869258702587125872258732587425875258762587725878258792588025881258822588325884258852588625887258882588925890258912589225893258942589525896258972589825899259002590125902259032590425905259062590725908259092591025911259122591325914259152591625917259182591925920259212592225923259242592525926259272592825929259302593125932259332593425935259362593725938259392594025941259422594325944259452594625947259482594925950259512595225953259542595525956259572595825959259602596125962259632596425965259662596725968259692597025971259722597325974259752597625977259782597925980259812598225983259842598525986259872598825989259902599125992259932599425995259962599725998259992600026001260022600326004260052600626007260082600926010260112601226013260142601526016260172601826019260202602126022260232602426025260262602726028260292603026031260322603326034260352603626037260382603926040260412604226043260442604526046260472604826049260502605126052260532605426055260562605726058260592606026061260622606326064260652606626067260682606926070260712607226073260742607526076260772607826079260802608126082260832608426085260862608726088260892609026091260922609326094260952609626097260982609926100261012610226103261042610526106261072610826109261102611126112261132611426115261162611726118261192612026121261222612326124261252612626127261282612926130261312613226133261342613526136261372613826139261402614126142261432614426145261462614726148261492615026151261522615326154261552615626157261582615926160261612616226163261642616526166261672616826169261702617126172261732617426175261762617726178261792618026181261822618326184261852618626187261882618926190261912619226193261942619526196261972619826199262002620126202262032620426205262062620726208262092621026211262122621326214262152621626217262182621926220262212622226223262242622526226262272622826229262302623126232262332623426235262362623726238262392624026241262422624326244262452624626247262482624926250262512625226253262542625526256262572625826259262602626126262262632626426265262662626726268262692627026271262722627326274262752627626277262782627926280262812628226283262842628526286262872628826289262902629126292262932629426295262962629726298262992630026301263022630326304263052630626307263082630926310263112631226313263142631526316263172631826319263202632126322263232632426325263262632726328263292633026331263322633326334263352633626337263382633926340263412634226343263442634526346263472634826349263502635126352263532635426355263562635726358263592636026361263622636326364263652636626367263682636926370263712637226373263742637526376263772637826379263802638126382263832638426385263862638726388263892639026391263922639326394263952639626397263982639926400264012640226403264042640526406264072640826409264102641126412264132641426415264162641726418264192642026421264222642326424264252642626427264282642926430264312643226433264342643526436264372643826439264402644126442264432644426445264462644726448264492645026451264522645326454264552645626457264582645926460264612646226463264642646526466264672646826469264702647126472264732647426475264762647726478264792648026481264822648326484264852648626487264882648926490264912649226493264942649526496264972649826499265002650126502265032650426505265062650726508265092651026511265122651326514265152651626517265182651926520265212652226523265242652526526265272652826529265302653126532265332653426535265362653726538265392654026541265422654326544265452654626547265482654926550265512655226553265542655526556265572655826559265602656126562265632656426565265662656726568265692657026571265722657326574265752657626577265782657926580265812658226583265842658526586265872658826589265902659126592265932659426595265962659726598265992660026601266022660326604266052660626607266082660926610266112661226613266142661526616266172661826619266202662126622266232662426625266262662726628266292663026631266322663326634266352663626637266382663926640266412664226643266442664526646266472664826649266502665126652266532665426655266562665726658266592666026661266622666326664266652666626667266682666926670266712667226673266742667526676266772667826679266802668126682266832668426685266862668726688266892669026691266922669326694266952669626697266982669926700267012670226703267042670526706267072670826709267102671126712267132671426715267162671726718267192672026721267222672326724267252672626727267282672926730267312673226733267342673526736267372673826739267402674126742267432674426745267462674726748267492675026751267522675326754267552675626757267582675926760267612676226763267642676526766267672676826769267702677126772267732677426775267762677726778267792678026781267822678326784267852678626787267882678926790267912679226793267942679526796267972679826799268002680126802268032680426805268062680726808268092681026811268122681326814268152681626817268182681926820268212682226823268242682526826268272682826829268302683126832268332683426835268362683726838268392684026841268422684326844268452684626847268482684926850268512685226853268542685526856268572685826859268602686126862268632686426865268662686726868268692687026871268722687326874268752687626877268782687926880268812688226883268842688526886268872688826889268902689126892268932689426895268962689726898268992690026901269022690326904269052690626907269082690926910269112691226913269142691526916269172691826919269202692126922269232692426925269262692726928269292693026931269322693326934269352693626937269382693926940269412694226943269442694526946269472694826949269502695126952269532695426955269562695726958269592696026961269622696326964269652696626967269682696926970269712697226973269742697526976269772697826979269802698126982269832698426985269862698726988269892699026991269922699326994269952699626997269982699927000270012700227003270042700527006270072700827009270102701127012270132701427015270162701727018270192702027021270222702327024270252702627027270282702927030270312703227033270342703527036270372703827039270402704127042270432704427045270462704727048270492705027051270522705327054270552705627057270582705927060270612706227063270642706527066270672706827069270702707127072270732707427075270762707727078270792708027081270822708327084270852708627087270882708927090270912709227093270942709527096270972709827099271002710127102271032710427105271062710727108271092711027111271122711327114271152711627117271182711927120271212712227123271242712527126271272712827129271302713127132271332713427135271362713727138271392714027141271422714327144271452714627147271482714927150271512715227153271542715527156271572715827159271602716127162271632716427165271662716727168271692717027171271722717327174271752717627177271782717927180271812718227183271842718527186271872718827189271902719127192271932719427195271962719727198271992720027201272022720327204272052720627207272082720927210272112721227213272142721527216272172721827219272202722127222272232722427225272262722727228272292723027231272322723327234272352723627237272382723927240272412724227243272442724527246272472724827249272502725127252272532725427255272562725727258272592726027261272622726327264272652726627267272682726927270272712727227273272742727527276272772727827279272802728127282272832728427285272862728727288272892729027291272922729327294272952729627297272982729927300273012730227303273042730527306273072730827309273102731127312273132731427315273162731727318273192732027321273222732327324273252732627327273282732927330273312733227333273342733527336273372733827339273402734127342273432734427345273462734727348273492735027351273522735327354273552735627357273582735927360273612736227363273642736527366273672736827369273702737127372273732737427375273762737727378273792738027381273822738327384273852738627387273882738927390273912739227393273942739527396273972739827399274002740127402274032740427405274062740727408274092741027411274122741327414274152741627417274182741927420274212742227423274242742527426274272742827429274302743127432274332743427435274362743727438274392744027441274422744327444274452744627447274482744927450274512745227453274542745527456274572745827459274602746127462274632746427465274662746727468274692747027471274722747327474274752747627477274782747927480274812748227483274842748527486274872748827489274902749127492274932749427495274962749727498274992750027501275022750327504275052750627507275082750927510275112751227513275142751527516275172751827519275202752127522275232752427525275262752727528275292753027531275322753327534275352753627537275382753927540275412754227543275442754527546275472754827549275502755127552275532755427555275562755727558275592756027561275622756327564275652756627567275682756927570275712757227573275742757527576275772757827579275802758127582275832758427585275862758727588275892759027591275922759327594275952759627597275982759927600276012760227603276042760527606276072760827609276102761127612276132761427615276162761727618276192762027621276222762327624276252762627627276282762927630276312763227633276342763527636276372763827639276402764127642276432764427645276462764727648276492765027651276522765327654276552765627657276582765927660276612766227663276642766527666276672766827669276702767127672276732767427675276762767727678276792768027681276822768327684276852768627687276882768927690276912769227693276942769527696276972769827699277002770127702277032770427705277062770727708277092771027711277122771327714277152771627717277182771927720277212772227723277242772527726277272772827729277302773127732277332773427735277362773727738277392774027741277422774327744277452774627747277482774927750277512775227753277542775527756277572775827759277602776127762277632776427765277662776727768277692777027771277722777327774277752777627777277782777927780277812778227783277842778527786277872778827789277902779127792277932779427795277962779727798277992780027801278022780327804278052780627807278082780927810278112781227813278142781527816278172781827819278202782127822278232782427825278262782727828278292783027831278322783327834278352783627837278382783927840278412784227843278442784527846278472784827849278502785127852278532785427855278562785727858278592786027861278622786327864278652786627867278682786927870278712787227873278742787527876278772787827879278802788127882278832788427885278862788727888278892789027891278922789327894278952789627897278982789927900279012790227903279042790527906279072790827909279102791127912279132791427915279162791727918279192792027921279222792327924279252792627927279282792927930279312793227933279342793527936279372793827939279402794127942279432794427945279462794727948279492795027951279522795327954279552795627957279582795927960279612796227963279642796527966279672796827969279702797127972279732797427975279762797727978279792798027981279822798327984279852798627987279882798927990279912799227993279942799527996279972799827999280002800128002280032800428005280062800728008280092801028011280122801328014280152801628017280182801928020280212802228023280242802528026280272802828029280302803128032280332803428035280362803728038280392804028041280422804328044280452804628047280482804928050280512805228053280542805528056280572805828059280602806128062280632806428065280662806728068280692807028071280722807328074280752807628077280782807928080280812808228083280842808528086280872808828089280902809128092280932809428095280962809728098280992810028101281022810328104281052810628107281082810928110281112811228113281142811528116281172811828119281202812128122281232812428125281262812728128281292813028131281322813328134281352813628137281382813928140281412814228143281442814528146281472814828149281502815128152281532815428155281562815728158281592816028161281622816328164281652816628167281682816928170281712817228173281742817528176281772817828179281802818128182281832818428185281862818728188281892819028191281922819328194281952819628197281982819928200282012820228203282042820528206282072820828209282102821128212282132821428215282162821728218282192822028221282222822328224282252822628227282282822928230282312823228233282342823528236282372823828239282402824128242282432824428245282462824728248282492825028251282522825328254282552825628257282582825928260282612826228263282642826528266282672826828269282702827128272282732827428275282762827728278282792828028281282822828328284282852828628287282882828928290282912829228293282942829528296282972829828299283002830128302283032830428305283062830728308283092831028311283122831328314283152831628317283182831928320283212832228323283242832528326283272832828329283302833128332283332833428335283362833728338283392834028341283422834328344283452834628347283482834928350283512835228353283542835528356283572835828359283602836128362283632836428365283662836728368283692837028371283722837328374283752837628377283782837928380283812838228383283842838528386283872838828389283902839128392283932839428395283962839728398283992840028401284022840328404284052840628407284082840928410284112841228413284142841528416284172841828419284202842128422284232842428425284262842728428284292843028431284322843328434284352843628437284382843928440284412844228443284442844528446284472844828449284502845128452284532845428455284562845728458284592846028461284622846328464284652846628467284682846928470284712847228473284742847528476284772847828479284802848128482284832848428485284862848728488284892849028491284922849328494284952849628497284982849928500285012850228503285042850528506285072850828509285102851128512285132851428515285162851728518285192852028521285222852328524285252852628527285282852928530285312853228533285342853528536285372853828539285402854128542285432854428545285462854728548285492855028551285522855328554285552855628557285582855928560285612856228563285642856528566285672856828569285702857128572285732857428575285762857728578285792858028581285822858328584285852858628587285882858928590285912859228593285942859528596285972859828599286002860128602286032860428605286062860728608286092861028611286122861328614286152861628617286182861928620286212862228623286242862528626286272862828629286302863128632286332863428635286362863728638286392864028641286422864328644286452864628647286482864928650286512865228653286542865528656286572865828659286602866128662286632866428665286662866728668286692867028671286722867328674286752867628677286782867928680286812868228683286842868528686286872868828689286902869128692286932869428695286962869728698286992870028701287022870328704287052870628707287082870928710287112871228713287142871528716287172871828719287202872128722287232872428725287262872728728287292873028731287322873328734287352873628737287382873928740287412874228743287442874528746287472874828749287502875128752287532875428755287562875728758287592876028761287622876328764287652876628767287682876928770287712877228773287742877528776287772877828779287802878128782287832878428785287862878728788287892879028791287922879328794287952879628797287982879928800288012880228803288042880528806288072880828809288102881128812288132881428815288162881728818288192882028821288222882328824288252882628827288282882928830288312883228833288342883528836288372883828839288402884128842288432884428845288462884728848288492885028851288522885328854288552885628857288582885928860288612886228863288642886528866288672886828869288702887128872288732887428875288762887728878288792888028881288822888328884288852888628887288882888928890288912889228893288942889528896288972889828899289002890128902289032890428905289062890728908289092891028911289122891328914289152891628917289182891928920289212892228923289242892528926289272892828929289302893128932289332893428935289362893728938289392894028941289422894328944289452894628947289482894928950289512895228953289542895528956289572895828959289602896128962289632896428965289662896728968289692897028971289722897328974289752897628977289782897928980289812898228983289842898528986289872898828989289902899128992289932899428995289962899728998289992900029001290022900329004290052900629007290082900929010290112901229013290142901529016290172901829019290202902129022290232902429025290262902729028290292903029031290322903329034290352903629037290382903929040290412904229043290442904529046290472904829049290502905129052290532905429055290562905729058290592906029061290622906329064290652906629067290682906929070290712907229073290742907529076290772907829079290802908129082290832908429085290862908729088290892909029091290922909329094290952909629097290982909929100291012910229103291042910529106291072910829109291102911129112291132911429115291162911729118291192912029121291222912329124291252912629127291282912929130291312913229133291342913529136291372913829139291402914129142291432914429145291462914729148291492915029151291522915329154291552915629157291582915929160291612916229163291642916529166291672916829169291702917129172291732917429175291762917729178291792918029181291822918329184291852918629187291882918929190291912919229193291942919529196291972919829199292002920129202292032920429205292062920729208292092921029211292122921329214292152921629217292182921929220292212922229223292242922529226292272922829229292302923129232292332923429235292362923729238292392924029241292422924329244292452924629247292482924929250292512925229253292542925529256292572925829259292602926129262292632926429265292662926729268292692927029271292722927329274292752927629277292782927929280292812928229283292842928529286292872928829289292902929129292292932929429295292962929729298292992930029301293022930329304293052930629307293082930929310293112931229313293142931529316293172931829319293202932129322293232932429325293262932729328293292933029331293322933329334293352933629337293382933929340293412934229343293442934529346293472934829349293502935129352293532935429355293562935729358293592936029361293622936329364293652936629367293682936929370293712937229373293742937529376293772937829379293802938129382293832938429385293862938729388293892939029391293922939329394293952939629397293982939929400294012940229403294042940529406294072940829409294102941129412294132941429415294162941729418294192942029421294222942329424294252942629427294282942929430294312943229433294342943529436294372943829439294402944129442294432944429445294462944729448294492945029451294522945329454294552945629457294582945929460294612946229463294642946529466294672946829469294702947129472294732947429475294762947729478294792948029481294822948329484294852948629487294882948929490294912949229493294942949529496294972949829499295002950129502295032950429505295062950729508295092951029511295122951329514295152951629517295182951929520295212952229523295242952529526295272952829529295302953129532295332953429535295362953729538295392954029541295422954329544295452954629547295482954929550295512955229553295542955529556295572955829559295602956129562295632956429565295662956729568295692957029571295722957329574295752957629577295782957929580295812958229583295842958529586295872958829589295902959129592295932959429595295962959729598295992960029601296022960329604296052960629607296082960929610296112961229613296142961529616296172961829619296202962129622296232962429625296262962729628296292963029631296322963329634296352963629637296382963929640296412964229643296442964529646296472964829649296502965129652296532965429655296562965729658296592966029661296622966329664296652966629667296682966929670296712967229673296742967529676296772967829679296802968129682296832968429685296862968729688296892969029691296922969329694296952969629697296982969929700297012970229703297042970529706297072970829709297102971129712297132971429715297162971729718297192972029721297222972329724297252972629727297282972929730297312973229733297342973529736297372973829739297402974129742297432974429745297462974729748297492975029751297522975329754297552975629757297582975929760297612976229763297642976529766297672976829769297702977129772297732977429775297762977729778297792978029781297822978329784297852978629787297882978929790297912979229793297942979529796297972979829799298002980129802298032980429805298062980729808298092981029811298122981329814298152981629817298182981929820298212982229823298242982529826298272982829829298302983129832298332983429835298362983729838298392984029841298422984329844298452984629847298482984929850298512985229853298542985529856298572985829859298602986129862298632986429865298662986729868298692987029871298722987329874298752987629877298782987929880298812988229883298842988529886298872988829889298902989129892298932989429895298962989729898298992990029901299022990329904299052990629907299082990929910299112991229913299142991529916299172991829919299202992129922299232992429925299262992729928299292993029931299322993329934299352993629937299382993929940299412994229943299442994529946299472994829949299502995129952299532995429955299562995729958299592996029961299622996329964299652996629967299682996929970299712997229973299742997529976299772997829979299802998129982299832998429985299862998729988299892999029991299922999329994299952999629997299982999930000300013000230003300043000530006300073000830009300103001130012300133001430015300163001730018300193002030021300223002330024300253002630027300283002930030300313003230033300343003530036300373003830039300403004130042300433004430045300463004730048300493005030051300523005330054300553005630057300583005930060300613006230063300643006530066300673006830069300703007130072300733007430075300763007730078300793008030081300823008330084300853008630087300883008930090300913009230093300943009530096300973009830099301003010130102301033010430105301063010730108301093011030111301123011330114301153011630117301183011930120301213012230123301243012530126301273012830129301303013130132301333013430135301363013730138301393014030141301423014330144301453014630147301483014930150301513015230153301543015530156301573015830159301603016130162301633016430165301663016730168301693017030171301723017330174301753017630177301783017930180301813018230183301843018530186301873018830189301903019130192301933019430195301963019730198301993020030201302023020330204302053020630207302083020930210302113021230213302143021530216302173021830219302203022130222302233022430225302263022730228302293023030231302323023330234302353023630237302383023930240302413024230243302443024530246302473024830249302503025130252302533025430255302563025730258302593026030261302623026330264302653026630267302683026930270302713027230273302743027530276302773027830279302803028130282302833028430285302863028730288302893029030291302923029330294302953029630297302983029930300303013030230303303043030530306303073030830309303103031130312303133031430315303163031730318303193032030321303223032330324303253032630327303283032930330303313033230333303343033530336303373033830339303403034130342303433034430345303463034730348303493035030351303523035330354303553035630357303583035930360303613036230363303643036530366303673036830369303703037130372303733037430375303763037730378303793038030381303823038330384303853038630387303883038930390303913039230393303943039530396303973039830399304003040130402304033040430405304063040730408304093041030411304123041330414304153041630417304183041930420304213042230423304243042530426304273042830429304303043130432304333043430435304363043730438304393044030441304423044330444304453044630447304483044930450304513045230453304543045530456304573045830459304603046130462304633046430465304663046730468304693047030471304723047330474304753047630477304783047930480304813048230483304843048530486304873048830489304903049130492304933049430495304963049730498304993050030501305023050330504305053050630507305083050930510305113051230513305143051530516305173051830519305203052130522305233052430525305263052730528305293053030531305323053330534305353053630537305383053930540305413054230543305443054530546305473054830549305503055130552305533055430555305563055730558305593056030561305623056330564305653056630567305683056930570305713057230573305743057530576305773057830579305803058130582305833058430585305863058730588305893059030591305923059330594305953059630597305983059930600306013060230603306043060530606306073060830609306103061130612306133061430615306163061730618306193062030621306223062330624306253062630627306283062930630306313063230633306343063530636306373063830639306403064130642306433064430645306463064730648306493065030651306523065330654306553065630657306583065930660306613066230663306643066530666306673066830669306703067130672306733067430675306763067730678306793068030681306823068330684306853068630687306883068930690306913069230693306943069530696306973069830699307003070130702307033070430705307063070730708307093071030711307123071330714307153071630717307183071930720307213072230723307243072530726307273072830729307303073130732307333073430735307363073730738307393074030741307423074330744307453074630747307483074930750307513075230753307543075530756307573075830759307603076130762307633076430765307663076730768307693077030771307723077330774307753077630777307783077930780307813078230783307843078530786307873078830789307903079130792307933079430795307963079730798307993080030801308023080330804308053080630807308083080930810308113081230813308143081530816308173081830819308203082130822308233082430825308263082730828308293083030831308323083330834308353083630837308383083930840308413084230843308443084530846308473084830849308503085130852308533085430855308563085730858308593086030861308623086330864308653086630867308683086930870308713087230873308743087530876308773087830879308803088130882308833088430885308863088730888308893089030891308923089330894308953089630897308983089930900309013090230903309043090530906309073090830909309103091130912309133091430915309163091730918309193092030921309223092330924309253092630927309283092930930309313093230933309343093530936309373093830939309403094130942309433094430945309463094730948309493095030951309523095330954309553095630957309583095930960309613096230963309643096530966309673096830969309703097130972309733097430975309763097730978309793098030981309823098330984309853098630987309883098930990309913099230993309943099530996309973099830999310003100131002310033100431005310063100731008310093101031011310123101331014310153101631017310183101931020310213102231023310243102531026310273102831029310303103131032310333103431035310363103731038310393104031041310423104331044310453104631047310483104931050310513105231053310543105531056310573105831059310603106131062310633106431065310663106731068310693107031071310723107331074310753107631077310783107931080310813108231083310843108531086310873108831089310903109131092310933109431095310963109731098310993110031101311023110331104311053110631107311083110931110311113111231113311143111531116311173111831119311203112131122311233112431125311263112731128311293113031131311323113331134311353113631137311383113931140311413114231143311443114531146311473114831149311503115131152311533115431155311563115731158311593116031161311623116331164311653116631167311683116931170311713117231173311743117531176311773117831179311803118131182311833118431185311863118731188311893119031191311923119331194311953119631197311983119931200312013120231203312043120531206312073120831209312103121131212312133121431215312163121731218312193122031221312223122331224312253122631227312283122931230312313123231233312343123531236312373123831239312403124131242312433124431245312463124731248312493125031251312523125331254312553125631257312583125931260312613126231263312643126531266312673126831269312703127131272312733127431275312763127731278312793128031281312823128331284312853128631287312883128931290312913129231293312943129531296312973129831299313003130131302313033130431305313063130731308313093131031311313123131331314313153131631317313183131931320313213132231323313243132531326313273132831329313303133131332313333133431335313363133731338313393134031341313423134331344313453134631347313483134931350313513135231353313543135531356313573135831359313603136131362313633136431365313663136731368313693137031371313723137331374313753137631377313783137931380313813138231383313843138531386313873138831389313903139131392313933139431395313963139731398313993140031401314023140331404314053140631407314083140931410314113141231413314143141531416314173141831419314203142131422314233142431425314263142731428314293143031431314323143331434314353143631437314383143931440314413144231443314443144531446314473144831449314503145131452314533145431455314563145731458314593146031461314623146331464314653146631467314683146931470314713147231473314743147531476314773147831479314803148131482314833148431485314863148731488314893149031491314923149331494314953149631497314983149931500315013150231503315043150531506315073150831509315103151131512315133151431515315163151731518315193152031521315223152331524315253152631527315283152931530315313153231533315343153531536315373153831539315403154131542315433154431545315463154731548315493155031551315523155331554315553155631557315583155931560315613156231563315643156531566315673156831569315703157131572315733157431575315763157731578315793158031581315823158331584315853158631587315883158931590315913159231593315943159531596315973159831599316003160131602316033160431605316063160731608316093161031611316123161331614316153161631617316183161931620316213162231623316243162531626316273162831629316303163131632316333163431635316363163731638316393164031641316423164331644316453164631647316483164931650316513165231653316543165531656316573165831659316603166131662316633166431665316663166731668316693167031671316723167331674316753167631677316783167931680316813168231683316843168531686316873168831689316903169131692316933169431695316963169731698316993170031701317023170331704317053170631707317083170931710317113171231713317143171531716317173171831719317203172131722317233172431725317263172731728317293173031731317323173331734317353173631737317383173931740317413174231743317443174531746317473174831749317503175131752317533175431755317563175731758317593176031761317623176331764317653176631767317683176931770317713177231773317743177531776317773177831779317803178131782317833178431785317863178731788317893179031791317923179331794317953179631797317983179931800318013180231803318043180531806318073180831809318103181131812318133181431815318163181731818318193182031821318223182331824318253182631827318283182931830318313183231833318343183531836318373183831839318403184131842318433184431845318463184731848318493185031851318523185331854318553185631857318583185931860318613186231863318643186531866318673186831869318703187131872318733187431875318763187731878318793188031881318823188331884318853188631887318883188931890318913189231893318943189531896318973189831899319003190131902319033190431905319063190731908319093191031911319123191331914319153191631917319183191931920319213192231923319243192531926319273192831929319303193131932319333193431935319363193731938319393194031941319423194331944319453194631947319483194931950319513195231953319543195531956319573195831959319603196131962319633196431965319663196731968319693197031971319723197331974319753197631977319783197931980319813198231983319843198531986319873198831989319903199131992319933199431995319963199731998319993200032001320023200332004320053200632007320083200932010320113201232013320143201532016320173201832019320203202132022320233202432025320263202732028320293203032031320323203332034320353203632037320383203932040320413204232043320443204532046320473204832049320503205132052320533205432055320563205732058320593206032061320623206332064320653206632067320683206932070320713207232073320743207532076320773207832079320803208132082320833208432085320863208732088320893209032091320923209332094320953209632097320983209932100321013210232103321043210532106321073210832109321103211132112321133211432115321163211732118321193212032121321223212332124321253212632127321283212932130321313213232133321343213532136321373213832139321403214132142321433214432145321463214732148321493215032151321523215332154321553215632157321583215932160321613216232163321643216532166321673216832169321703217132172321733217432175321763217732178321793218032181321823218332184321853218632187321883218932190321913219232193321943219532196321973219832199322003220132202322033220432205322063220732208322093221032211322123221332214322153221632217322183221932220322213222232223322243222532226322273222832229322303223132232322333223432235322363223732238322393224032241322423224332244322453224632247322483224932250322513225232253322543225532256322573225832259322603226132262322633226432265322663226732268322693227032271322723227332274322753227632277322783227932280322813228232283322843228532286322873228832289322903229132292322933229432295322963229732298322993230032301323023230332304323053230632307323083230932310323113231232313323143231532316323173231832319323203232132322323233232432325323263232732328323293233032331323323233332334323353233632337323383233932340323413234232343323443234532346323473234832349323503235132352323533235432355323563235732358323593236032361323623236332364323653236632367323683236932370323713237232373323743237532376323773237832379323803238132382323833238432385323863238732388323893239032391323923239332394323953239632397323983239932400324013240232403324043240532406324073240832409324103241132412324133241432415324163241732418324193242032421324223242332424324253242632427324283242932430324313243232433324343243532436324373243832439324403244132442324433244432445324463244732448324493245032451324523245332454324553245632457324583245932460324613246232463324643246532466324673246832469324703247132472324733247432475324763247732478324793248032481324823248332484324853248632487324883248932490324913249232493324943249532496324973249832499325003250132502325033250432505325063250732508325093251032511325123251332514325153251632517325183251932520325213252232523325243252532526325273252832529325303253132532325333253432535325363253732538325393254032541325423254332544325453254632547325483254932550325513255232553325543255532556325573255832559325603256132562325633256432565325663256732568325693257032571325723257332574325753257632577325783257932580325813258232583325843258532586325873258832589325903259132592325933259432595325963259732598325993260032601326023260332604326053260632607326083260932610326113261232613326143261532616326173261832619326203262132622326233262432625326263262732628326293263032631326323263332634326353263632637326383263932640326413264232643326443264532646326473264832649326503265132652326533265432655326563265732658326593266032661326623266332664326653266632667326683266932670326713267232673326743267532676326773267832679326803268132682326833268432685326863268732688326893269032691326923269332694326953269632697326983269932700327013270232703327043270532706327073270832709327103271132712327133271432715327163271732718327193272032721327223272332724327253272632727327283272932730327313273232733327343273532736327373273832739327403274132742327433274432745327463274732748327493275032751327523275332754327553275632757327583275932760327613276232763327643276532766327673276832769327703277132772327733277432775327763277732778327793278032781327823278332784327853278632787327883278932790327913279232793327943279532796327973279832799328003280132802328033280432805328063280732808328093281032811328123281332814328153281632817328183281932820328213282232823328243282532826328273282832829328303283132832328333283432835328363283732838328393284032841328423284332844328453284632847328483284932850328513285232853328543285532856328573285832859328603286132862328633286432865328663286732868328693287032871328723287332874328753287632877328783287932880328813288232883328843288532886328873288832889328903289132892328933289432895328963289732898328993290032901329023290332904329053290632907329083290932910329113291232913329143291532916329173291832919329203292132922329233292432925329263292732928329293293032931329323293332934329353293632937329383293932940329413294232943329443294532946329473294832949329503295132952329533295432955329563295732958329593296032961329623296332964329653296632967329683296932970329713297232973329743297532976329773297832979329803298132982329833298432985329863298732988329893299032991329923299332994329953299632997329983299933000330013300233003330043300533006330073300833009330103301133012330133301433015330163301733018330193302033021330223302333024330253302633027330283302933030330313303233033330343303533036330373303833039330403304133042330433304433045330463304733048330493305033051330523305333054330553305633057330583305933060330613306233063330643306533066330673306833069330703307133072330733307433075330763307733078330793308033081330823308333084330853308633087330883308933090330913309233093330943309533096330973309833099331003310133102331033310433105331063310733108331093311033111331123311333114331153311633117331183311933120331213312233123331243312533126331273312833129331303313133132331333313433135331363313733138331393314033141331423314333144331453314633147331483314933150331513315233153331543315533156331573315833159331603316133162331633316433165331663316733168331693317033171331723317333174331753317633177331783317933180331813318233183331843318533186331873318833189331903319133192331933319433195331963319733198331993320033201332023320333204332053320633207332083320933210332113321233213332143321533216332173321833219332203322133222332233322433225332263322733228332293323033231332323323333234332353323633237332383323933240332413324233243332443324533246332473324833249332503325133252332533325433255332563325733258332593326033261332623326333264332653326633267332683326933270332713327233273332743327533276332773327833279332803328133282332833328433285332863328733288332893329033291332923329333294332953329633297332983329933300333013330233303333043330533306333073330833309333103331133312333133331433315333163331733318333193332033321333223332333324333253332633327333283332933330333313333233333333343333533336333373333833339333403334133342333433334433345333463334733348333493335033351333523335333354333553335633357333583335933360333613336233363333643336533366333673336833369333703337133372333733337433375333763337733378333793338033381333823338333384333853338633387333883338933390333913339233393333943339533396333973339833399334003340133402334033340433405334063340733408334093341033411334123341333414334153341633417334183341933420334213342233423334243342533426334273342833429334303343133432334333343433435334363343733438334393344033441334423344333444334453344633447334483344933450334513345233453334543345533456334573345833459334603346133462334633346433465334663346733468334693347033471334723347333474334753347633477334783347933480334813348233483334843348533486334873348833489334903349133492334933349433495334963349733498334993350033501335023350333504335053350633507335083350933510335113351233513335143351533516335173351833519335203352133522335233352433525335263352733528335293353033531335323353333534335353353633537335383353933540335413354233543335443354533546335473354833549335503355133552335533355433555335563355733558335593356033561335623356333564335653356633567335683356933570335713357233573335743357533576335773357833579335803358133582335833358433585335863358733588335893359033591335923359333594335953359633597335983359933600336013360233603336043360533606336073360833609336103361133612336133361433615336163361733618336193362033621336223362333624336253362633627336283362933630336313363233633336343363533636336373363833639336403364133642336433364433645336463364733648336493365033651336523365333654336553365633657336583365933660336613366233663336643366533666336673366833669336703367133672336733367433675336763367733678336793368033681336823368333684336853368633687336883368933690336913369233693336943369533696336973369833699337003370133702337033370433705337063370733708337093371033711337123371333714337153371633717337183371933720337213372233723337243372533726337273372833729337303373133732337333373433735337363373733738337393374033741337423374333744337453374633747337483374933750337513375233753337543375533756337573375833759337603376133762337633376433765337663376733768337693377033771337723377333774337753377633777337783377933780337813378233783337843378533786337873378833789337903379133792337933379433795337963379733798337993380033801338023380333804338053380633807338083380933810338113381233813338143381533816338173381833819338203382133822338233382433825338263382733828338293383033831338323383333834338353383633837338383383933840338413384233843338443384533846338473384833849338503385133852338533385433855338563385733858338593386033861338623386333864338653386633867338683386933870338713387233873338743387533876338773387833879338803388133882338833388433885338863388733888338893389033891338923389333894338953389633897338983389933900339013390233903339043390533906339073390833909339103391133912339133391433915339163391733918339193392033921339223392333924339253392633927339283392933930339313393233933339343393533936339373393833939339403394133942339433394433945339463394733948339493395033951339523395333954339553395633957339583395933960339613396233963339643396533966339673396833969339703397133972339733397433975339763397733978339793398033981339823398333984339853398633987339883398933990339913399233993339943399533996339973399833999340003400134002340033400434005340063400734008340093401034011340123401334014340153401634017340183401934020340213402234023340243402534026340273402834029340303403134032340333403434035340363403734038340393404034041340423404334044340453404634047340483404934050340513405234053340543405534056340573405834059340603406134062340633406434065340663406734068340693407034071340723407334074340753407634077340783407934080340813408234083340843408534086340873408834089340903409134092340933409434095340963409734098340993410034101341023410334104341053410634107341083410934110341113411234113341143411534116341173411834119341203412134122341233412434125341263412734128341293413034131341323413334134341353413634137341383413934140341413414234143341443414534146341473414834149341503415134152341533415434155341563415734158341593416034161341623416334164341653416634167341683416934170341713417234173341743417534176341773417834179341803418134182341833418434185341863418734188341893419034191341923419334194341953419634197341983419934200342013420234203342043420534206342073420834209342103421134212342133421434215342163421734218342193422034221342223422334224342253422634227342283422934230342313423234233342343423534236342373423834239342403424134242342433424434245342463424734248342493425034251342523425334254342553425634257342583425934260342613426234263342643426534266342673426834269342703427134272342733427434275
  1. #! /bin/sh
  2. # From configure.ac Revision: 432815 .
  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. GMIME_LIBS
  603. GMIME_CFLAGS
  604. OPENH323_BUILD
  605. OPENH323_SUFFIX
  606. OPENH323_LIBDIR
  607. OPENH323_INCDIR
  608. OPENH323DIR
  609. PWLIB_PLATFORM
  610. PWLIB_LIBDIR
  611. PWLIB_INCDIR
  612. PWLIBDIR
  613. PTLIB_CONFIG
  614. PJPROJECT_LIBS
  615. PJPROJECT_CFLAGS
  616. PG_CONFIG
  617. CONFIG_NETSNMP
  618. CONFIG_NEON29
  619. CONFIG_NEON
  620. CONFIG_MYSQLCLIENT
  621. PBX_MISDN_FAC_ERROR
  622. PBX_MISDN_FAC_RESULT
  623. LIBEDIT_LIBS
  624. LIBEDIT_CFLAGS
  625. LIBEDIT_INTERNAL
  626. ILBC_LIBS
  627. ILBC_CFLAGS
  628. ILBC_INTERNAL
  629. GSM_INTERNAL
  630. PBX_DAHDI_HALF_FULL
  631. PKG_CONFIG_LIBDIR
  632. PKG_CONFIG_PATH
  633. PKG_CONFIG
  634. PBX_DLADDR
  635. PBX_IP_MTU_DISCOVER
  636. PBX_RTLD_NOLOAD
  637. PBX_GLOB_BRACE
  638. PBX_GLOB_NOMAGIC
  639. AST_RPATH
  640. AST_CLANG_BLOCKS
  641. AST_CLANG_BLOCKS_LIBS
  642. AST_NESTED_FUNCTIONS
  643. AST_NATIVE_ARCH
  644. AST_SHADOW_WARNINGS
  645. AST_NO_STRICT_OVERFLOW
  646. AST_FORTIFY_SOURCE
  647. AST_TRAMPOLINES
  648. AST_DECLARATION_AFTER_STATEMENT
  649. GC_LDFLAGS
  650. GC_CFLAGS
  651. PBX_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
  652. PBX_PTHREAD_RWLOCK_INITIALIZER
  653. AST_ASTERISKSSL
  654. HAS_POLL
  655. PBX_DYNAMIC_LIST
  656. POW_LIB
  657. PBX_WORKING_FORK
  658. LIBOBJS
  659. CONFIG_LIBXML2
  660. UUID_LIB
  661. UUID_INCLUDE
  662. EDITLINE_LIB
  663. ALLOCA
  664. PBX_ZLIB
  665. ZLIB_DIR
  666. ZLIB_INCLUDE
  667. ZLIB_LIB
  668. PBX_X11
  669. X11_DIR
  670. X11_INCLUDE
  671. X11_LIB
  672. PBX_VPB
  673. VPB_DIR
  674. VPB_INCLUDE
  675. VPB_LIB
  676. PBX_VORBIS
  677. VORBIS_DIR
  678. VORBIS_INCLUDE
  679. VORBIS_LIB
  680. PBX_UNIXODBC
  681. UNIXODBC_DIR
  682. UNIXODBC_INCLUDE
  683. UNIXODBC_LIB
  684. PBX_UNBOUND
  685. UNBOUND_DIR
  686. UNBOUND_INCLUDE
  687. UNBOUND_LIB
  688. PBX_TONEZONE
  689. TONEZONE_DIR
  690. TONEZONE_INCLUDE
  691. TONEZONE_LIB
  692. PBX_TINFO
  693. TINFO_DIR
  694. TINFO_INCLUDE
  695. TINFO_LIB
  696. PBX_TIMERFD
  697. TIMERFD_DIR
  698. TIMERFD_INCLUDE
  699. TIMERFD_LIB
  700. PBX_TERMCAP
  701. TERMCAP_DIR
  702. TERMCAP_INCLUDE
  703. TERMCAP_LIB
  704. PBX_FREETDS
  705. FREETDS_DIR
  706. FREETDS_INCLUDE
  707. FREETDS_LIB
  708. PBX_SUPPSERV
  709. SUPPSERV_DIR
  710. SUPPSERV_INCLUDE
  711. SUPPSERV_LIB
  712. PBX_OPENSSL
  713. OPENSSL_DIR
  714. OPENSSL_INCLUDE
  715. OPENSSL_LIB
  716. PBX_SRTP_SHUTDOWN
  717. SRTP_SHUTDOWN_DIR
  718. SRTP_SHUTDOWN_INCLUDE
  719. SRTP_SHUTDOWN_LIB
  720. PBX_SRTP
  721. SRTP_DIR
  722. SRTP_INCLUDE
  723. SRTP_LIB
  724. PBX_SQLITE3
  725. SQLITE3_DIR
  726. SQLITE3_INCLUDE
  727. SQLITE3_LIB
  728. PBX_SQLITE
  729. SQLITE_DIR
  730. SQLITE_INCLUDE
  731. SQLITE_LIB
  732. PBX_SPEEXDSP
  733. SPEEXDSP_DIR
  734. SPEEXDSP_INCLUDE
  735. SPEEXDSP_LIB
  736. PBX_SPEEX_PREPROCESS
  737. SPEEX_PREPROCESS_DIR
  738. SPEEX_PREPROCESS_INCLUDE
  739. SPEEX_PREPROCESS_LIB
  740. PBX_SPEEX
  741. SPEEX_DIR
  742. SPEEX_INCLUDE
  743. SPEEX_LIB
  744. PBX_SS7
  745. SS7_DIR
  746. SS7_INCLUDE
  747. SS7_LIB
  748. PBX_SPANDSP
  749. SPANDSP_DIR
  750. SPANDSP_INCLUDE
  751. SPANDSP_LIB
  752. SOUNDS_CACHE_DIR
  753. PBX_SDL_IMAGE
  754. SDL_IMAGE_DIR
  755. SDL_IMAGE_INCLUDE
  756. SDL_IMAGE_LIB
  757. PBX_SDL
  758. SDL_DIR
  759. SDL_INCLUDE
  760. SDL_LIB
  761. PBX_RESAMPLE
  762. RESAMPLE_DIR
  763. RESAMPLE_INCLUDE
  764. RESAMPLE_LIB
  765. PBX_RADIUS
  766. RADIUS_DIR
  767. RADIUS_INCLUDE
  768. RADIUS_LIB
  769. PBX_PWLIB
  770. PWLIB_DIR
  771. PWLIB_INCLUDE
  772. PWLIB_LIB
  773. PBX_PRI_REVERSE_CHARGE
  774. PRI_REVERSE_CHARGE_DIR
  775. PRI_REVERSE_CHARGE_INCLUDE
  776. PRI_REVERSE_CHARGE_LIB
  777. PBX_PRI_SERVICE_MESSAGES
  778. PRI_SERVICE_MESSAGES_DIR
  779. PRI_SERVICE_MESSAGES_INCLUDE
  780. PRI_SERVICE_MESSAGES_LIB
  781. PBX_PRI_PROG_W_CAUSE
  782. PRI_PROG_W_CAUSE_DIR
  783. PRI_PROG_W_CAUSE_INCLUDE
  784. PRI_PROG_W_CAUSE_LIB
  785. PBX_PRI_INBANDDISCONNECT
  786. PRI_INBANDDISCONNECT_DIR
  787. PRI_INBANDDISCONNECT_INCLUDE
  788. PRI_INBANDDISCONNECT_LIB
  789. PBX_PRI_SETUP_KEYPAD
  790. PRI_SETUP_KEYPAD_DIR
  791. PRI_SETUP_KEYPAD_INCLUDE
  792. PRI_SETUP_KEYPAD_LIB
  793. PBX_PRI_CALL_REROUTING
  794. PRI_CALL_REROUTING_DIR
  795. PRI_CALL_REROUTING_INCLUDE
  796. PRI_CALL_REROUTING_LIB
  797. PBX_PRI_CALL_HOLD
  798. PRI_CALL_HOLD_DIR
  799. PRI_CALL_HOLD_INCLUDE
  800. PRI_CALL_HOLD_LIB
  801. PBX_PRI_SUBADDR
  802. PRI_SUBADDR_DIR
  803. PRI_SUBADDR_INCLUDE
  804. PRI_SUBADDR_LIB
  805. PBX_PRI_HANGUP_FIX
  806. PRI_HANGUP_FIX_DIR
  807. PRI_HANGUP_FIX_INCLUDE
  808. PRI_HANGUP_FIX_LIB
  809. PBX_PRI_CCSS
  810. PRI_CCSS_DIR
  811. PRI_CCSS_INCLUDE
  812. PRI_CCSS_LIB
  813. PBX_PRI_TRANSFER
  814. PRI_TRANSFER_DIR
  815. PRI_TRANSFER_INCLUDE
  816. PRI_TRANSFER_LIB
  817. PBX_PRI_AOC_EVENTS
  818. PRI_AOC_EVENTS_DIR
  819. PRI_AOC_EVENTS_INCLUDE
  820. PRI_AOC_EVENTS_LIB
  821. PBX_PRI_CALL_WAITING
  822. PRI_CALL_WAITING_DIR
  823. PRI_CALL_WAITING_INCLUDE
  824. PRI_CALL_WAITING_LIB
  825. PBX_PRI_MCID
  826. PRI_MCID_DIR
  827. PRI_MCID_INCLUDE
  828. PRI_MCID_LIB
  829. PBX_PRI_MWI
  830. PRI_MWI_DIR
  831. PRI_MWI_INCLUDE
  832. PRI_MWI_LIB
  833. PBX_PRI_DISPLAY_TEXT
  834. PRI_DISPLAY_TEXT_DIR
  835. PRI_DISPLAY_TEXT_INCLUDE
  836. PRI_DISPLAY_TEXT_LIB
  837. PBX_PRI_MWI_V2
  838. PRI_MWI_V2_DIR
  839. PRI_MWI_V2_INCLUDE
  840. PRI_MWI_V2_LIB
  841. PBX_PRI_DATETIME_SEND
  842. PRI_DATETIME_SEND_DIR
  843. PRI_DATETIME_SEND_INCLUDE
  844. PRI_DATETIME_SEND_LIB
  845. PBX_PRI_L2_PERSISTENCE
  846. PRI_L2_PERSISTENCE_DIR
  847. PRI_L2_PERSISTENCE_INCLUDE
  848. PRI_L2_PERSISTENCE_LIB
  849. PBX_PRI_SETUP_ACK_INBAND
  850. PRI_SETUP_ACK_INBAND_DIR
  851. PRI_SETUP_ACK_INBAND_INCLUDE
  852. PRI_SETUP_ACK_INBAND_LIB
  853. PBX_PRI
  854. PRI_DIR
  855. PRI_INCLUDE
  856. PRI_LIB
  857. PBX_PORTAUDIO
  858. PORTAUDIO_DIR
  859. PORTAUDIO_INCLUDE
  860. PORTAUDIO_LIB
  861. PBX_PJ_SSL_CERT_LOAD_FROM_FILES2
  862. PJ_SSL_CERT_LOAD_FROM_FILES2_DIR
  863. PJ_SSL_CERT_LOAD_FROM_FILES2_INCLUDE
  864. PJ_SSL_CERT_LOAD_FROM_FILES2_LIB
  865. PBX_PJSIP_GET_DEST_INFO
  866. PJSIP_GET_DEST_INFO_DIR
  867. PJSIP_GET_DEST_INFO_INCLUDE
  868. PJSIP_GET_DEST_INFO_LIB
  869. PBX_PJSIP_REPLACE_MEDIA_STREAM
  870. PJSIP_REPLACE_MEDIA_STREAM_DIR
  871. PJSIP_REPLACE_MEDIA_STREAM_INCLUDE
  872. PJSIP_REPLACE_MEDIA_STREAM_LIB
  873. PBX_PJ_TRANSACTION_GRP_LOCK
  874. PJ_TRANSACTION_GRP_LOCK_DIR
  875. PJ_TRANSACTION_GRP_LOCK_INCLUDE
  876. PJ_TRANSACTION_GRP_LOCK_LIB
  877. PBX_POPT
  878. POPT_DIR
  879. POPT_INCLUDE
  880. POPT_LIB
  881. PBX_PJPROJECT
  882. PJPROJECT_DIR
  883. PJPROJECT_INCLUDE
  884. PJPROJECT_LIB
  885. PBX_PGSQL
  886. PGSQL_DIR
  887. PGSQL_INCLUDE
  888. PGSQL_LIB
  889. PBX_OSS
  890. OSS_DIR
  891. OSS_INCLUDE
  892. OSS_LIB
  893. PBX_OSPTK
  894. OSPTK_DIR
  895. OSPTK_INCLUDE
  896. OSPTK_LIB
  897. PBX_OPUS
  898. OPUS_DIR
  899. OPUS_INCLUDE
  900. OPUS_LIB
  901. PBX_OPENR2
  902. OPENR2_DIR
  903. OPENR2_INCLUDE
  904. OPENR2_LIB
  905. PBX_OGG
  906. OGG_DIR
  907. OGG_INCLUDE
  908. OGG_LIB
  909. PBX_NEWT
  910. NEWT_DIR
  911. NEWT_INCLUDE
  912. NEWT_LIB
  913. PBX_NETSNMP
  914. NETSNMP_DIR
  915. NETSNMP_INCLUDE
  916. NETSNMP_LIB
  917. PBX_NEON29
  918. NEON29_DIR
  919. NEON29_INCLUDE
  920. NEON29_LIB
  921. PBX_NEON
  922. NEON_DIR
  923. NEON_INCLUDE
  924. NEON_LIB
  925. PBX_NCURSES
  926. NCURSES_DIR
  927. NCURSES_INCLUDE
  928. NCURSES_LIB
  929. PBX_NBS
  930. NBS_DIR
  931. NBS_INCLUDE
  932. NBS_LIB
  933. PBX_MYSQLCLIENT
  934. MYSQLCLIENT_DIR
  935. MYSQLCLIENT_INCLUDE
  936. MYSQLCLIENT_LIB
  937. PBX_MISDN
  938. MISDN_DIR
  939. MISDN_INCLUDE
  940. MISDN_LIB
  941. PBX_LUA
  942. LUA_DIR
  943. LUA_INCLUDE
  944. LUA_LIB
  945. PBX_LTDL
  946. LTDL_DIR
  947. LTDL_INCLUDE
  948. LTDL_LIB
  949. PBX_LIBXSLT_CLEANUP
  950. LIBXSLT_CLEANUP_DIR
  951. LIBXSLT_CLEANUP_INCLUDE
  952. LIBXSLT_CLEANUP_LIB
  953. PBX_LIBXSLT
  954. LIBXSLT_DIR
  955. LIBXSLT_INCLUDE
  956. LIBXSLT_LIB
  957. PBX_LIBXML2
  958. LIBXML2_DIR
  959. LIBXML2_INCLUDE
  960. LIBXML2_LIB
  961. PBX_LIBEDIT
  962. LIBEDIT_DIR
  963. LIBEDIT_INCLUDE
  964. LIBEDIT_LIB
  965. CURL_LIB
  966. CURL_INCLUDE
  967. _libcurl_config
  968. PBX_CURL
  969. PBX_LDAP
  970. LDAP_DIR
  971. LDAP_INCLUDE
  972. LDAP_LIB
  973. PBX_KQUEUE
  974. KQUEUE_DIR
  975. KQUEUE_INCLUDE
  976. KQUEUE_LIB
  977. PBX_URIPARSER
  978. URIPARSER_DIR
  979. URIPARSER_INCLUDE
  980. URIPARSER_LIB
  981. PBX_JANSSON
  982. JANSSON_DIR
  983. JANSSON_INCLUDE
  984. JANSSON_LIB
  985. PBX_JACK
  986. JACK_DIR
  987. JACK_INCLUDE
  988. JACK_LIB
  989. PBX_ISDNNET
  990. ISDNNET_DIR
  991. ISDNNET_INCLUDE
  992. ISDNNET_LIB
  993. PBX_IODBC
  994. IODBC_DIR
  995. IODBC_INCLUDE
  996. IODBC_LIB
  997. PBX_INOTIFY
  998. INOTIFY_DIR
  999. INOTIFY_INCLUDE
  1000. INOTIFY_LIB
  1001. PBX_IMAP_TK
  1002. IMAP_TK_DIR
  1003. IMAP_TK_INCLUDE
  1004. IMAP_TK_LIB
  1005. PBX_IKSEMEL
  1006. IKSEMEL_DIR
  1007. IKSEMEL_INCLUDE
  1008. IKSEMEL_LIB
  1009. PBX_ICONV
  1010. ICONV_DIR
  1011. ICONV_INCLUDE
  1012. ICONV_LIB
  1013. PBX_ICAL
  1014. ICAL_DIR
  1015. ICAL_INCLUDE
  1016. ICAL_LIB
  1017. PBX_HOARD
  1018. HOARD_DIR
  1019. HOARD_INCLUDE
  1020. HOARD_LIB
  1021. PBX_OPENH323
  1022. OPENH323_DIR
  1023. OPENH323_INCLUDE
  1024. OPENH323_LIB
  1025. PBX_GMIME
  1026. GMIME_DIR
  1027. GMIME_INCLUDE
  1028. GMIME_LIB
  1029. PBX_GTK2
  1030. GTK2_DIR
  1031. GTK2_INCLUDE
  1032. GTK2_LIB
  1033. PBX_ILBC
  1034. ILBC_DIR
  1035. ILBC_INCLUDE
  1036. ILBC_LIB
  1037. PBX_GSM
  1038. GSM_DIR
  1039. GSM_INCLUDE
  1040. GSM_LIB
  1041. PBX_FFMPEG
  1042. FFMPEG_DIR
  1043. FFMPEG_INCLUDE
  1044. FFMPEG_LIB
  1045. PBX_DAHDI
  1046. DAHDI_DIR
  1047. DAHDI_INCLUDE
  1048. DAHDI_LIB
  1049. PBX_OPENSSL_EC
  1050. OPENSSL_EC_DIR
  1051. OPENSSL_EC_INCLUDE
  1052. OPENSSL_EC_LIB
  1053. PBX_OPENSSL_SRTP
  1054. OPENSSL_SRTP_DIR
  1055. OPENSSL_SRTP_INCLUDE
  1056. OPENSSL_SRTP_LIB
  1057. PBX_CRYPTO
  1058. CRYPTO_DIR
  1059. CRYPTO_INCLUDE
  1060. CRYPTO_LIB
  1061. PBX_CRYPT
  1062. CRYPT_DIR
  1063. CRYPT_INCLUDE
  1064. CRYPT_LIB
  1065. PBX_CURSES
  1066. CURSES_DIR
  1067. CURSES_INCLUDE
  1068. CURSES_LIB
  1069. PBX_COROSYNC_CFG_STATE_TRACK
  1070. COROSYNC_CFG_STATE_TRACK_DIR
  1071. COROSYNC_CFG_STATE_TRACK_INCLUDE
  1072. COROSYNC_CFG_STATE_TRACK_LIB
  1073. PBX_COROSYNC
  1074. COROSYNC_DIR
  1075. COROSYNC_INCLUDE
  1076. COROSYNC_LIB
  1077. PBX_CAP
  1078. CAP_DIR
  1079. CAP_INCLUDE
  1080. CAP_LIB
  1081. PBX_BLUETOOTH
  1082. BLUETOOTH_DIR
  1083. BLUETOOTH_INCLUDE
  1084. BLUETOOTH_LIB
  1085. PBX_BKTR
  1086. BKTR_DIR
  1087. BKTR_INCLUDE
  1088. BKTR_LIB
  1089. PBX_BFD
  1090. BFD_DIR
  1091. BFD_INCLUDE
  1092. BFD_LIB
  1093. PBX_ALSA
  1094. ALSA_DIR
  1095. ALSA_INCLUDE
  1096. ALSA_LIB
  1097. AST_CODE_COVERAGE
  1098. AST_DEVMODE_STRICT
  1099. AST_DEVMODE
  1100. NOISY_BUILD
  1101. PTHREAD_CFLAGS
  1102. PTHREAD_LIBS
  1103. PTHREAD_CC
  1104. acx_pthread_config
  1105. MD5
  1106. SOXMIX
  1107. PBX_FLEX
  1108. PBX_BISON
  1109. OPENSSL
  1110. SHA1SUM
  1111. LDCONFIG
  1112. DOWNLOAD
  1113. FETCH
  1114. GIT
  1115. XMLSTARLET
  1116. XMLLINT
  1117. KPATHSEA
  1118. CATDVI
  1119. RUBBER
  1120. CURL
  1121. WGET
  1122. DOT
  1123. DOXYGEN
  1124. LN
  1125. DIRNAME
  1126. BASENAME
  1127. COMPRESS
  1128. FIND
  1129. PYTHON
  1130. FLEX
  1131. CMP
  1132. BISON
  1133. GNU_LD
  1134. ac_ct_AR
  1135. AR
  1136. ac_ct_STRIP
  1137. STRIP
  1138. GNU_MAKE
  1139. LN_S
  1140. INSTALL_DATA
  1141. INSTALL_SCRIPT
  1142. INSTALL_PROGRAM
  1143. AWK
  1144. SED
  1145. CXXCPP
  1146. ac_ct_CXX
  1147. CXXFLAGS
  1148. RANLIB
  1149. LD
  1150. CXX
  1151. PBX_OSREV
  1152. UNAME
  1153. CONFIG_SIGNED_CHAR
  1154. PBX_WINARCH
  1155. OSARCH
  1156. HOST_OS
  1157. HOST_VENDOR
  1158. HOST_CPU
  1159. HOST_PLATFORM
  1160. BUILD_OS
  1161. BUILD_VENDOR
  1162. BUILD_CPU
  1163. BUILD_PLATFORM
  1164. astvarrundir
  1165. astlogdir
  1166. astspooldir
  1167. astkeydir
  1168. astdbdir
  1169. astdatadir
  1170. astvarlibdir
  1171. astmandir
  1172. astmoddir
  1173. astlibdir
  1174. astheaderdir
  1175. astetcdir
  1176. astsbindir
  1177. EGREP
  1178. GREP
  1179. CPP
  1180. OBJEXT
  1181. EXEEXT
  1182. ac_ct_CC
  1183. CPPFLAGS
  1184. LDFLAGS
  1185. CFLAGS
  1186. CC
  1187. CONFIG_LDFLAGS
  1188. CONFIG_CFLAGS
  1189. host_os
  1190. host_vendor
  1191. host_cpu
  1192. host
  1193. build_os
  1194. build_vendor
  1195. build_cpu
  1196. build
  1197. target_alias
  1198. host_alias
  1199. build_alias
  1200. LIBS
  1201. ECHO_T
  1202. ECHO_N
  1203. ECHO_C
  1204. DEFS
  1205. mandir
  1206. localedir
  1207. libdir
  1208. psdir
  1209. pdfdir
  1210. dvidir
  1211. htmldir
  1212. infodir
  1213. docdir
  1214. oldincludedir
  1215. includedir
  1216. localstatedir
  1217. sharedstatedir
  1218. sysconfdir
  1219. datadir
  1220. datarootdir
  1221. libexecdir
  1222. sbindir
  1223. bindir
  1224. program_transform_name
  1225. prefix
  1226. exec_prefix
  1227. PACKAGE_URL
  1228. PACKAGE_BUGREPORT
  1229. PACKAGE_STRING
  1230. PACKAGE_VERSION
  1231. PACKAGE_TARNAME
  1232. PACKAGE_NAME
  1233. PATH_SEPARATOR
  1234. SHELL'
  1235. ac_subst_files=''
  1236. ac_user_opts='
  1237. enable_option_checking
  1238. with_gnu_ld
  1239. enable_dev_mode
  1240. enable_coverage
  1241. with_asound
  1242. with_bfd
  1243. with_execinfo
  1244. with_bluetooth
  1245. with_cap
  1246. with_cpg
  1247. with_curses
  1248. with_crypt
  1249. with_crypto
  1250. with_dahdi
  1251. with_avcodec
  1252. with_gsm
  1253. with_ilbc
  1254. with_gtk2
  1255. with_gmime
  1256. with_h323
  1257. with_hoard
  1258. with_ical
  1259. with_iconv
  1260. with_iksemel
  1261. with_imap
  1262. with_inotify
  1263. with_iodbc
  1264. with_isdnnet
  1265. with_jack
  1266. with_jansson
  1267. with_uriparser
  1268. with_kqueue
  1269. with_ldap
  1270. with_libcurl
  1271. with_libedit
  1272. with_libxml2
  1273. with_libxslt
  1274. with_ltdl
  1275. with_lua
  1276. with_misdn
  1277. with_mysqlclient
  1278. with_nbs
  1279. with_ncurses
  1280. with_neon
  1281. with_neon29
  1282. with_netsnmp
  1283. with_newt
  1284. with_ogg
  1285. with_openr2
  1286. with_opus
  1287. with_osptk
  1288. with_oss
  1289. with_postgres
  1290. with_pjproject
  1291. with_popt
  1292. with_portaudio
  1293. with_pri
  1294. with_pwlib
  1295. with_radius
  1296. with_resample
  1297. with_sdl
  1298. with_SDL_image
  1299. with_sounds_cache
  1300. with_spandsp
  1301. with_ss7
  1302. with_speex
  1303. with_speexdsp
  1304. with_sqlite
  1305. with_sqlite3
  1306. with_srtp
  1307. with_ssl
  1308. with_suppserv
  1309. with_tds
  1310. with_termcap
  1311. with_timerfd
  1312. with_tinfo
  1313. with_tonezone
  1314. with_unbound
  1315. with_unixodbc
  1316. with_vorbis
  1317. with_vpb
  1318. with_x11
  1319. with_z
  1320. enable_xmldoc
  1321. enable_largefile
  1322. enable_internal_poll
  1323. enable_asteriskssl
  1324. enable_rpath
  1325. '
  1326. ac_precious_vars='build_alias
  1327. host_alias
  1328. target_alias
  1329. CC
  1330. CFLAGS
  1331. LDFLAGS
  1332. LIBS
  1333. CPPFLAGS
  1334. CPP
  1335. CXX
  1336. CXXFLAGS
  1337. CCC
  1338. CXXCPP
  1339. PKG_CONFIG
  1340. PKG_CONFIG_PATH
  1341. PKG_CONFIG_LIBDIR
  1342. ILBC_CFLAGS
  1343. ILBC_LIBS
  1344. LIBEDIT_CFLAGS
  1345. LIBEDIT_LIBS
  1346. PJPROJECT_CFLAGS
  1347. PJPROJECT_LIBS
  1348. GMIME_CFLAGS
  1349. GMIME_LIBS
  1350. GTK2_CFLAGS
  1351. GTK2_LIBS'
  1352. # Initialize some variables set by options.
  1353. ac_init_help=
  1354. ac_init_version=false
  1355. ac_unrecognized_opts=
  1356. ac_unrecognized_sep=
  1357. # The variables have the same names as the options, with
  1358. # dashes changed to underlines.
  1359. cache_file=/dev/null
  1360. exec_prefix=NONE
  1361. no_create=
  1362. no_recursion=
  1363. prefix=NONE
  1364. program_prefix=NONE
  1365. program_suffix=NONE
  1366. program_transform_name=s,x,x,
  1367. silent=
  1368. site=
  1369. srcdir=
  1370. verbose=
  1371. x_includes=NONE
  1372. x_libraries=NONE
  1373. # Installation directory options.
  1374. # These are left unexpanded so users can "make install exec_prefix=/foo"
  1375. # and all the variables that are supposed to be based on exec_prefix
  1376. # by default will actually change.
  1377. # Use braces instead of parens because sh, perl, etc. also accept them.
  1378. # (The list follows the same order as the GNU Coding Standards.)
  1379. bindir='${exec_prefix}/bin'
  1380. sbindir='${exec_prefix}/sbin'
  1381. libexecdir='${exec_prefix}/libexec'
  1382. datarootdir='${prefix}/share'
  1383. datadir='${datarootdir}'
  1384. sysconfdir='${prefix}/etc'
  1385. sharedstatedir='${prefix}/com'
  1386. localstatedir='${prefix}/var'
  1387. includedir='${prefix}/include'
  1388. oldincludedir='/usr/include'
  1389. docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
  1390. infodir='${datarootdir}/info'
  1391. htmldir='${docdir}'
  1392. dvidir='${docdir}'
  1393. pdfdir='${docdir}'
  1394. psdir='${docdir}'
  1395. libdir='${exec_prefix}/lib'
  1396. localedir='${datarootdir}/locale'
  1397. mandir='${datarootdir}/man'
  1398. ac_prev=
  1399. ac_dashdash=
  1400. for ac_option
  1401. do
  1402. # If the previous option needs an argument, assign it.
  1403. if test -n "$ac_prev"; then
  1404. eval $ac_prev=\$ac_option
  1405. ac_prev=
  1406. continue
  1407. fi
  1408. case $ac_option in
  1409. *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
  1410. *=) ac_optarg= ;;
  1411. *) ac_optarg=yes ;;
  1412. esac
  1413. # Accept the important Cygnus configure options, so we can diagnose typos.
  1414. case $ac_dashdash$ac_option in
  1415. --)
  1416. ac_dashdash=yes ;;
  1417. -bindir | --bindir | --bindi | --bind | --bin | --bi)
  1418. ac_prev=bindir ;;
  1419. -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
  1420. bindir=$ac_optarg ;;
  1421. -build | --build | --buil | --bui | --bu)
  1422. ac_prev=build_alias ;;
  1423. -build=* | --build=* | --buil=* | --bui=* | --bu=*)
  1424. build_alias=$ac_optarg ;;
  1425. -cache-file | --cache-file | --cache-fil | --cache-fi \
  1426. | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  1427. ac_prev=cache_file ;;
  1428. -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  1429. | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  1430. cache_file=$ac_optarg ;;
  1431. --config-cache | -C)
  1432. cache_file=config.cache ;;
  1433. -datadir | --datadir | --datadi | --datad)
  1434. ac_prev=datadir ;;
  1435. -datadir=* | --datadir=* | --datadi=* | --datad=*)
  1436. datadir=$ac_optarg ;;
  1437. -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
  1438. | --dataroo | --dataro | --datar)
  1439. ac_prev=datarootdir ;;
  1440. -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
  1441. | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
  1442. datarootdir=$ac_optarg ;;
  1443. -disable-* | --disable-*)
  1444. ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
  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--disable-$ac_useropt_orig"
  1455. ac_unrecognized_sep=', ';;
  1456. esac
  1457. eval enable_$ac_useropt=no ;;
  1458. -docdir | --docdir | --docdi | --doc | --do)
  1459. ac_prev=docdir ;;
  1460. -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
  1461. docdir=$ac_optarg ;;
  1462. -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
  1463. ac_prev=dvidir ;;
  1464. -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
  1465. dvidir=$ac_optarg ;;
  1466. -enable-* | --enable-*)
  1467. ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
  1468. # Reject names that are not valid shell variable names.
  1469. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1470. as_fn_error $? "invalid feature name: $ac_useropt"
  1471. ac_useropt_orig=$ac_useropt
  1472. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1473. case $ac_user_opts in
  1474. *"
  1475. "enable_$ac_useropt"
  1476. "*) ;;
  1477. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
  1478. ac_unrecognized_sep=', ';;
  1479. esac
  1480. eval enable_$ac_useropt=\$ac_optarg ;;
  1481. -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  1482. | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  1483. | --exec | --exe | --ex)
  1484. ac_prev=exec_prefix ;;
  1485. -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  1486. | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  1487. | --exec=* | --exe=* | --ex=*)
  1488. exec_prefix=$ac_optarg ;;
  1489. -gas | --gas | --ga | --g)
  1490. # Obsolete; use --with-gas.
  1491. with_gas=yes ;;
  1492. -help | --help | --hel | --he | -h)
  1493. ac_init_help=long ;;
  1494. -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
  1495. ac_init_help=recursive ;;
  1496. -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
  1497. ac_init_help=short ;;
  1498. -host | --host | --hos | --ho)
  1499. ac_prev=host_alias ;;
  1500. -host=* | --host=* | --hos=* | --ho=*)
  1501. host_alias=$ac_optarg ;;
  1502. -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
  1503. ac_prev=htmldir ;;
  1504. -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
  1505. | --ht=*)
  1506. htmldir=$ac_optarg ;;
  1507. -includedir | --includedir | --includedi | --included | --include \
  1508. | --includ | --inclu | --incl | --inc)
  1509. ac_prev=includedir ;;
  1510. -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  1511. | --includ=* | --inclu=* | --incl=* | --inc=*)
  1512. includedir=$ac_optarg ;;
  1513. -infodir | --infodir | --infodi | --infod | --info | --inf)
  1514. ac_prev=infodir ;;
  1515. -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
  1516. infodir=$ac_optarg ;;
  1517. -libdir | --libdir | --libdi | --libd)
  1518. ac_prev=libdir ;;
  1519. -libdir=* | --libdir=* | --libdi=* | --libd=*)
  1520. libdir=$ac_optarg ;;
  1521. -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  1522. | --libexe | --libex | --libe)
  1523. ac_prev=libexecdir ;;
  1524. -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  1525. | --libexe=* | --libex=* | --libe=*)
  1526. libexecdir=$ac_optarg ;;
  1527. -localedir | --localedir | --localedi | --localed | --locale)
  1528. ac_prev=localedir ;;
  1529. -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
  1530. localedir=$ac_optarg ;;
  1531. -localstatedir | --localstatedir | --localstatedi | --localstated \
  1532. | --localstate | --localstat | --localsta | --localst | --locals)
  1533. ac_prev=localstatedir ;;
  1534. -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  1535. | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
  1536. localstatedir=$ac_optarg ;;
  1537. -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
  1538. ac_prev=mandir ;;
  1539. -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
  1540. mandir=$ac_optarg ;;
  1541. -nfp | --nfp | --nf)
  1542. # Obsolete; use --without-fp.
  1543. with_fp=no ;;
  1544. -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  1545. | --no-cr | --no-c | -n)
  1546. no_create=yes ;;
  1547. -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  1548. | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  1549. no_recursion=yes ;;
  1550. -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  1551. | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  1552. | --oldin | --oldi | --old | --ol | --o)
  1553. ac_prev=oldincludedir ;;
  1554. -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  1555. | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  1556. | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
  1557. oldincludedir=$ac_optarg ;;
  1558. -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  1559. ac_prev=prefix ;;
  1560. -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  1561. prefix=$ac_optarg ;;
  1562. -program-prefix | --program-prefix | --program-prefi | --program-pref \
  1563. | --program-pre | --program-pr | --program-p)
  1564. ac_prev=program_prefix ;;
  1565. -program-prefix=* | --program-prefix=* | --program-prefi=* \
  1566. | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  1567. program_prefix=$ac_optarg ;;
  1568. -program-suffix | --program-suffix | --program-suffi | --program-suff \
  1569. | --program-suf | --program-su | --program-s)
  1570. ac_prev=program_suffix ;;
  1571. -program-suffix=* | --program-suffix=* | --program-suffi=* \
  1572. | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  1573. program_suffix=$ac_optarg ;;
  1574. -program-transform-name | --program-transform-name \
  1575. | --program-transform-nam | --program-transform-na \
  1576. | --program-transform-n | --program-transform- \
  1577. | --program-transform | --program-transfor \
  1578. | --program-transfo | --program-transf \
  1579. | --program-trans | --program-tran \
  1580. | --progr-tra | --program-tr | --program-t)
  1581. ac_prev=program_transform_name ;;
  1582. -program-transform-name=* | --program-transform-name=* \
  1583. | --program-transform-nam=* | --program-transform-na=* \
  1584. | --program-transform-n=* | --program-transform-=* \
  1585. | --program-transform=* | --program-transfor=* \
  1586. | --program-transfo=* | --program-transf=* \
  1587. | --program-trans=* | --program-tran=* \
  1588. | --progr-tra=* | --program-tr=* | --program-t=*)
  1589. program_transform_name=$ac_optarg ;;
  1590. -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
  1591. ac_prev=pdfdir ;;
  1592. -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
  1593. pdfdir=$ac_optarg ;;
  1594. -psdir | --psdir | --psdi | --psd | --ps)
  1595. ac_prev=psdir ;;
  1596. -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
  1597. psdir=$ac_optarg ;;
  1598. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  1599. | -silent | --silent | --silen | --sile | --sil)
  1600. silent=yes ;;
  1601. -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
  1602. ac_prev=sbindir ;;
  1603. -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  1604. | --sbi=* | --sb=*)
  1605. sbindir=$ac_optarg ;;
  1606. -sharedstatedir | --sharedstatedir | --sharedstatedi \
  1607. | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  1608. | --sharedst | --shareds | --shared | --share | --shar \
  1609. | --sha | --sh)
  1610. ac_prev=sharedstatedir ;;
  1611. -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  1612. | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  1613. | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  1614. | --sha=* | --sh=*)
  1615. sharedstatedir=$ac_optarg ;;
  1616. -site | --site | --sit)
  1617. ac_prev=site ;;
  1618. -site=* | --site=* | --sit=*)
  1619. site=$ac_optarg ;;
  1620. -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  1621. ac_prev=srcdir ;;
  1622. -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  1623. srcdir=$ac_optarg ;;
  1624. -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  1625. | --syscon | --sysco | --sysc | --sys | --sy)
  1626. ac_prev=sysconfdir ;;
  1627. -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  1628. | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
  1629. sysconfdir=$ac_optarg ;;
  1630. -target | --target | --targe | --targ | --tar | --ta | --t)
  1631. ac_prev=target_alias ;;
  1632. -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  1633. target_alias=$ac_optarg ;;
  1634. -v | -verbose | --verbose | --verbos | --verbo | --verb)
  1635. verbose=yes ;;
  1636. -version | --version | --versio | --versi | --vers | -V)
  1637. ac_init_version=: ;;
  1638. -with-* | --with-*)
  1639. ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
  1640. # Reject names that are not valid shell variable names.
  1641. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1642. as_fn_error $? "invalid package name: $ac_useropt"
  1643. ac_useropt_orig=$ac_useropt
  1644. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1645. case $ac_user_opts in
  1646. *"
  1647. "with_$ac_useropt"
  1648. "*) ;;
  1649. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
  1650. ac_unrecognized_sep=', ';;
  1651. esac
  1652. eval with_$ac_useropt=\$ac_optarg ;;
  1653. -without-* | --without-*)
  1654. ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
  1655. # Reject names that are not valid shell variable names.
  1656. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
  1657. as_fn_error $? "invalid package name: $ac_useropt"
  1658. ac_useropt_orig=$ac_useropt
  1659. ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
  1660. case $ac_user_opts in
  1661. *"
  1662. "with_$ac_useropt"
  1663. "*) ;;
  1664. *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
  1665. ac_unrecognized_sep=', ';;
  1666. esac
  1667. eval with_$ac_useropt=no ;;
  1668. --x)
  1669. # Obsolete; use --with-x.
  1670. with_x=yes ;;
  1671. -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  1672. | --x-incl | --x-inc | --x-in | --x-i)
  1673. ac_prev=x_includes ;;
  1674. -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  1675. | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  1676. x_includes=$ac_optarg ;;
  1677. -x-libraries | --x-libraries | --x-librarie | --x-librari \
  1678. | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  1679. ac_prev=x_libraries ;;
  1680. -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  1681. | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  1682. x_libraries=$ac_optarg ;;
  1683. -*) as_fn_error $? "unrecognized option: \`$ac_option'
  1684. Try \`$0 --help' for more information"
  1685. ;;
  1686. *=*)
  1687. ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
  1688. # Reject names that are not valid shell variable names.
  1689. case $ac_envvar in #(
  1690. '' | [0-9]* | *[!_$as_cr_alnum]* )
  1691. as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
  1692. esac
  1693. eval $ac_envvar=\$ac_optarg
  1694. export $ac_envvar ;;
  1695. *)
  1696. # FIXME: should be removed in autoconf 3.0.
  1697. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
  1698. expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
  1699. $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
  1700. : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
  1701. ;;
  1702. esac
  1703. done
  1704. if test -n "$ac_prev"; then
  1705. ac_option=--`echo $ac_prev | sed 's/_/-/g'`
  1706. as_fn_error $? "missing argument to $ac_option"
  1707. fi
  1708. if test -n "$ac_unrecognized_opts"; then
  1709. case $enable_option_checking in
  1710. no) ;;
  1711. fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
  1712. *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
  1713. esac
  1714. fi
  1715. # Check all directory arguments for consistency.
  1716. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
  1717. datadir sysconfdir sharedstatedir localstatedir includedir \
  1718. oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
  1719. libdir localedir mandir
  1720. do
  1721. eval ac_val=\$$ac_var
  1722. # Remove trailing slashes.
  1723. case $ac_val in
  1724. */ )
  1725. ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
  1726. eval $ac_var=\$ac_val;;
  1727. esac
  1728. # Be sure to have absolute directory names.
  1729. case $ac_val in
  1730. [\\/$]* | ?:[\\/]* ) continue;;
  1731. NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
  1732. esac
  1733. as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
  1734. done
  1735. # There might be people who depend on the old broken behavior: `$host'
  1736. # used to hold the argument of --host etc.
  1737. # FIXME: To remove some day.
  1738. build=$build_alias
  1739. host=$host_alias
  1740. target=$target_alias
  1741. # FIXME: To remove some day.
  1742. if test "x$host_alias" != x; then
  1743. if test "x$build_alias" = x; then
  1744. cross_compiling=maybe
  1745. elif test "x$build_alias" != "x$host_alias"; then
  1746. cross_compiling=yes
  1747. fi
  1748. fi
  1749. ac_tool_prefix=
  1750. test -n "$host_alias" && ac_tool_prefix=$host_alias-
  1751. test "$silent" = yes && exec 6>/dev/null
  1752. ac_pwd=`pwd` && test -n "$ac_pwd" &&
  1753. ac_ls_di=`ls -di .` &&
  1754. ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
  1755. as_fn_error $? "working directory cannot be determined"
  1756. test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
  1757. as_fn_error $? "pwd does not report name of working directory"
  1758. # Find the source files, if location was not specified.
  1759. if test -z "$srcdir"; then
  1760. ac_srcdir_defaulted=yes
  1761. # Try the directory containing this script, then the parent directory.
  1762. ac_confdir=`$as_dirname -- "$as_myself" ||
  1763. $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  1764. X"$as_myself" : 'X\(//\)[^/]' \| \
  1765. X"$as_myself" : 'X\(//\)$' \| \
  1766. X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
  1767. $as_echo X"$as_myself" |
  1768. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  1769. s//\1/
  1770. q
  1771. }
  1772. /^X\(\/\/\)[^/].*/{
  1773. s//\1/
  1774. q
  1775. }
  1776. /^X\(\/\/\)$/{
  1777. s//\1/
  1778. q
  1779. }
  1780. /^X\(\/\).*/{
  1781. s//\1/
  1782. q
  1783. }
  1784. s/.*/./; q'`
  1785. srcdir=$ac_confdir
  1786. if test ! -r "$srcdir/$ac_unique_file"; then
  1787. srcdir=..
  1788. fi
  1789. else
  1790. ac_srcdir_defaulted=no
  1791. fi
  1792. if test ! -r "$srcdir/$ac_unique_file"; then
  1793. test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
  1794. as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
  1795. fi
  1796. ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
  1797. ac_abs_confdir=`(
  1798. cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
  1799. pwd)`
  1800. # When building in place, set srcdir=.
  1801. if test "$ac_abs_confdir" = "$ac_pwd"; then
  1802. srcdir=.
  1803. fi
  1804. # Remove unnecessary trailing slashes from srcdir.
  1805. # Double slashes in file names in object file debugging info
  1806. # mess up M-x gdb in Emacs.
  1807. case $srcdir in
  1808. */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
  1809. esac
  1810. for ac_var in $ac_precious_vars; do
  1811. eval ac_env_${ac_var}_set=\${${ac_var}+set}
  1812. eval ac_env_${ac_var}_value=\$${ac_var}
  1813. eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
  1814. eval ac_cv_env_${ac_var}_value=\$${ac_var}
  1815. done
  1816. #
  1817. # Report the --help message.
  1818. #
  1819. if test "$ac_init_help" = "long"; then
  1820. # Omit some internal or obsolete options to make the list less imposing.
  1821. # This message is too long to be a string in the A/UX 3.1 sh.
  1822. cat <<_ACEOF
  1823. \`configure' configures asterisk trunk to adapt to many kinds of systems.
  1824. Usage: $0 [OPTION]... [VAR=VALUE]...
  1825. To assign environment variables (e.g., CC, CFLAGS...), specify them as
  1826. VAR=VALUE. See below for descriptions of some of the useful variables.
  1827. Defaults for the options are specified in brackets.
  1828. Configuration:
  1829. -h, --help display this help and exit
  1830. --help=short display options specific to this package
  1831. --help=recursive display the short help of all the included packages
  1832. -V, --version display version information and exit
  1833. -q, --quiet, --silent do not print \`checking ...' messages
  1834. --cache-file=FILE cache test results in FILE [disabled]
  1835. -C, --config-cache alias for \`--cache-file=config.cache'
  1836. -n, --no-create do not create output files
  1837. --srcdir=DIR find the sources in DIR [configure dir or \`..']
  1838. Installation directories:
  1839. --prefix=PREFIX install architecture-independent files in PREFIX
  1840. [$ac_default_prefix]
  1841. --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
  1842. [PREFIX]
  1843. By default, \`make install' will install all the files in
  1844. \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
  1845. an installation prefix other than \`$ac_default_prefix' using \`--prefix',
  1846. for instance \`--prefix=\$HOME'.
  1847. For better control, use the options below.
  1848. Fine tuning of the installation directories:
  1849. --bindir=DIR user executables [EPREFIX/bin]
  1850. --sbindir=DIR system admin executables [EPREFIX/sbin]
  1851. --libexecdir=DIR program executables [EPREFIX/libexec]
  1852. --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
  1853. --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
  1854. --localstatedir=DIR modifiable single-machine data [PREFIX/var]
  1855. --libdir=DIR object code libraries [EPREFIX/lib]
  1856. --includedir=DIR C header files [PREFIX/include]
  1857. --oldincludedir=DIR C header files for non-gcc [/usr/include]
  1858. --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
  1859. --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
  1860. --infodir=DIR info documentation [DATAROOTDIR/info]
  1861. --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
  1862. --mandir=DIR man documentation [DATAROOTDIR/man]
  1863. --docdir=DIR documentation root [DATAROOTDIR/doc/asterisk]
  1864. --htmldir=DIR html documentation [DOCDIR]
  1865. --dvidir=DIR dvi documentation [DOCDIR]
  1866. --pdfdir=DIR pdf documentation [DOCDIR]
  1867. --psdir=DIR ps documentation [DOCDIR]
  1868. _ACEOF
  1869. cat <<\_ACEOF
  1870. System types:
  1871. --build=BUILD configure for building on BUILD [guessed]
  1872. --host=HOST cross-compile to build programs to run on HOST [BUILD]
  1873. _ACEOF
  1874. fi
  1875. if test -n "$ac_init_help"; then
  1876. case $ac_init_help in
  1877. short | recursive ) echo "Configuration of asterisk trunk:";;
  1878. esac
  1879. cat <<\_ACEOF
  1880. Optional Features:
  1881. --disable-option-checking ignore unrecognized --enable/--with options
  1882. --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
  1883. --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
  1884. --enable-dev-mode Turn on developer mode
  1885. --enable-coverage Turn on code coverage tracking (for gcov)
  1886. --disable-xmldoc Explicitly disable XML documentation
  1887. --disable-largefile omit support for large files
  1888. --enable-internal-poll Use Asterisk's poll implementation
  1889. --disable-asteriskssl Disable Asterisk's SSL wrapper library
  1890. --disable-rpath Disables rpath linker option checking
  1891. Optional Packages:
  1892. --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
  1893. --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
  1894. --with-gnu-ld assume the C compiler uses GNU ld [default=no]
  1895. --with-asound=PATH use Advanced Linux Sound Architecture files in PATH
  1896. --with-bfd=PATH use Debug symbol decoding files in PATH
  1897. --with-execinfo=PATH use Stack Backtrace files in PATH
  1898. --with-bluetooth=PATH use Bluetooth files in PATH
  1899. --with-cap=PATH use POSIX 1.e capabilities files in PATH
  1900. --with-cpg=PATH use Corosync files in PATH
  1901. --with-curses=PATH use curses files in PATH
  1902. --with-crypt=PATH use password and data encryption files in PATH
  1903. --with-crypto=PATH use OpenSSL Cryptography files in PATH
  1904. --with-dahdi=PATH use DAHDI files in PATH
  1905. --with-avcodec=PATH use Ffmpeg and avcodec files in PATH
  1906. --with-gsm=PATH use External GSM files in PATH, use 'internal' GSM
  1907. otherwise
  1908. --with-ilbc=PATH use System iLBC files in PATH, use 'internal' iLBC
  1909. otherwise
  1910. --with-gtk2=PATH use gtk2 files in PATH
  1911. --with-gmime=PATH use GMime files in PATH
  1912. --with-h323=PATH use OpenH323 files in PATH
  1913. --with-hoard=PATH use Hoard Memory Allocator files in PATH
  1914. --with-ical=PATH use iCal files in PATH
  1915. --with-iconv=PATH use Iconv files in PATH
  1916. --with-iksemel=PATH use Iksemel Jabber files in PATH
  1917. --with-imap=PATH use UW IMAP Toolkit files in PATH
  1918. --with-inotify=PATH use inotify support files in PATH
  1919. --with-iodbc=PATH use iODBC files in PATH
  1920. --with-isdnnet=PATH use ISDN4Linux files in PATH
  1921. --with-jack=PATH use Jack Audio Connection Kit files in PATH
  1922. --with-jansson=PATH use Jansson JSON library files in PATH
  1923. --with-uriparser=PATH use uriparser library files in PATH
  1924. --with-kqueue=PATH use kqueue support files in PATH
  1925. --with-ldap=PATH use OpenLDAP files in PATH
  1926. --with-libcurl=DIR look for the curl library in DIR
  1927. --with-libedit=PATH use NetBSD Editline library files in PATH, use
  1928. 'internal' Editline otherwise
  1929. --with-libxml2=PATH use LibXML2 files in PATH
  1930. --with-libxslt=PATH use LibXSLT files in PATH
  1931. --with-ltdl=PATH use libtool files in PATH
  1932. --with-lua=PATH use Lua files in PATH
  1933. --with-misdn=PATH use mISDN user files in PATH
  1934. --with-mysqlclient=PATH use MySQL client files in PATH
  1935. --with-nbs=PATH use Network Broadcast Sound files in PATH
  1936. --with-ncurses=PATH use ncurses files in PATH
  1937. --with-neon=PATH use neon files in PATH
  1938. --with-neon29=PATH use neon29 files in PATH
  1939. --with-netsnmp=PATH use Net-SNMP files in PATH
  1940. --with-newt=PATH use newt files in PATH
  1941. --with-ogg=PATH use OGG files in PATH
  1942. --with-openr2=PATH use MFR2 files in PATH
  1943. --with-opus=PATH use Opus files in PATH
  1944. --with-osptk=PATH use OSP Toolkit files in PATH
  1945. --with-oss=PATH use Open Sound System files in PATH
  1946. --with-postgres=PATH use PostgreSQL files in PATH
  1947. --with-pjproject=PATH use PJPROJECT files in PATH
  1948. --with-popt=PATH use popt files in PATH
  1949. --with-portaudio=PATH use PortAudio files in PATH
  1950. --with-pri=PATH use ISDN PRI files in PATH
  1951. --with-pwlib=PATH use PWlib files in PATH
  1952. --with-radius=PATH use Radius Client files in PATH
  1953. --with-resample=PATH use LIBRESAMPLE files in PATH
  1954. --with-sdl=PATH use Sdl files in PATH
  1955. --with-SDL_image=PATH use Sdl Image files in PATH
  1956. --with-sounds-cache=PATH
  1957. use cached sound tarfiles in PATH
  1958. --with-spandsp=PATH use SPANDSP files in PATH
  1959. --with-ss7=PATH use ISDN SS7 files in PATH
  1960. --with-speex=PATH use Speex files in PATH
  1961. --with-speex=PATH use Speex preprocess routines files in PATH
  1962. --with-speexdsp=PATH use SpeexDSP files in PATH
  1963. --with-sqlite=PATH use SQLite files in PATH
  1964. --with-sqlite3=PATH use SQLite files in PATH
  1965. --with-srtp=PATH use Secure RTP files in PATH
  1966. --with-ssl=PATH use OpenSSL Secure Sockets Layer files in PATH
  1967. --with-suppserv=PATH use mISDN Supplemental Services files in PATH
  1968. --with-tds=PATH use FreeTDS files in PATH
  1969. --with-termcap=PATH use Termcap files in PATH
  1970. --with-timerfd=PATH use timerfd files in PATH
  1971. --with-tinfo=PATH use Term Info files in PATH
  1972. --with-tonezone=PATH use tonezone files in PATH
  1973. --with-unbound=PATH use unbound files in PATH
  1974. --with-unixodbc=PATH use unixODBC files in PATH
  1975. --with-vorbis=PATH use Vorbis files in PATH
  1976. --with-vpb=PATH use Voicetronix API files in PATH
  1977. --with-x11=PATH use X11 files in PATH
  1978. --with-z=PATH use zlib compression files in PATH
  1979. Some influential environment variables:
  1980. CC C compiler command
  1981. CFLAGS C compiler flags
  1982. LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
  1983. nonstandard directory <lib dir>
  1984. LIBS libraries to pass to the linker, e.g. -l<library>
  1985. CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
  1986. you have headers in a nonstandard directory <include dir>
  1987. CPP C preprocessor
  1988. CXX C++ compiler command
  1989. CXXFLAGS C++ compiler flags
  1990. CXXCPP C++ preprocessor
  1991. PKG_CONFIG path to pkg-config utility
  1992. PKG_CONFIG_PATH
  1993. directories to add to pkg-config's search path
  1994. PKG_CONFIG_LIBDIR
  1995. path overriding pkg-config's built-in search path
  1996. ILBC_CFLAGS C compiler flags for ILBC, overriding pkg-config
  1997. ILBC_LIBS linker flags for ILBC, overriding pkg-config
  1998. LIBEDIT_CFLAGS
  1999. C compiler flags for LIBEDIT, overriding pkg-config
  2000. LIBEDIT_LIBS
  2001. linker flags for LIBEDIT, overriding pkg-config
  2002. PJPROJECT_CFLAGS
  2003. C compiler flags for PJPROJECT, overriding pkg-config
  2004. PJPROJECT_LIBS
  2005. linker flags for PJPROJECT, overriding pkg-config
  2006. GMIME_CFLAGS
  2007. C compiler flags for GMIME, overriding pkg-config
  2008. GMIME_LIBS linker flags for GMIME, overriding pkg-config
  2009. GTK2_CFLAGS C compiler flags for GTK2, overriding pkg-config
  2010. GTK2_LIBS linker flags for GTK2, overriding pkg-config
  2011. Use these variables to override the choices made by `configure' or to help
  2012. it to find libraries and programs with nonstandard names/locations.
  2013. Report bugs to <https://issues.asterisk.org>.
  2014. _ACEOF
  2015. ac_status=$?
  2016. fi
  2017. if test "$ac_init_help" = "recursive"; then
  2018. # If there are subdirs, report their specific --help.
  2019. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
  2020. test -d "$ac_dir" ||
  2021. { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
  2022. continue
  2023. ac_builddir=.
  2024. case "$ac_dir" in
  2025. .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
  2026. *)
  2027. ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  2028. # A ".." for each directory in $ac_dir_suffix.
  2029. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  2030. case $ac_top_builddir_sub in
  2031. "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  2032. *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  2033. esac ;;
  2034. esac
  2035. ac_abs_top_builddir=$ac_pwd
  2036. ac_abs_builddir=$ac_pwd$ac_dir_suffix
  2037. # for backward compatibility:
  2038. ac_top_builddir=$ac_top_build_prefix
  2039. case $srcdir in
  2040. .) # We are building in place.
  2041. ac_srcdir=.
  2042. ac_top_srcdir=$ac_top_builddir_sub
  2043. ac_abs_top_srcdir=$ac_pwd ;;
  2044. [\\/]* | ?:[\\/]* ) # Absolute name.
  2045. ac_srcdir=$srcdir$ac_dir_suffix;
  2046. ac_top_srcdir=$srcdir
  2047. ac_abs_top_srcdir=$srcdir ;;
  2048. *) # Relative name.
  2049. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
  2050. ac_top_srcdir=$ac_top_build_prefix$srcdir
  2051. ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
  2052. esac
  2053. ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
  2054. cd "$ac_dir" || { ac_status=$?; continue; }
  2055. # Check for guested configure.
  2056. if test -f "$ac_srcdir/configure.gnu"; then
  2057. echo &&
  2058. $SHELL "$ac_srcdir/configure.gnu" --help=recursive
  2059. elif test -f "$ac_srcdir/configure"; then
  2060. echo &&
  2061. $SHELL "$ac_srcdir/configure" --help=recursive
  2062. else
  2063. $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
  2064. fi || ac_status=$?
  2065. cd "$ac_pwd" || { ac_status=$?; break; }
  2066. done
  2067. fi
  2068. test -n "$ac_init_help" && exit $ac_status
  2069. if $ac_init_version; then
  2070. cat <<\_ACEOF
  2071. asterisk configure trunk
  2072. generated by GNU Autoconf 2.69
  2073. Copyright (C) 2012 Free Software Foundation, Inc.
  2074. This configure script is free software; the Free Software Foundation
  2075. gives unlimited permission to copy, distribute and modify it.
  2076. "Asterisk"
  2077. _ACEOF
  2078. exit
  2079. fi
  2080. ## ------------------------ ##
  2081. ## Autoconf initialization. ##
  2082. ## ------------------------ ##
  2083. # ac_fn_c_try_compile LINENO
  2084. # --------------------------
  2085. # Try to compile conftest.$ac_ext, and return whether this succeeded.
  2086. ac_fn_c_try_compile ()
  2087. {
  2088. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2089. rm -f conftest.$ac_objext
  2090. if { { ac_try="$ac_compile"
  2091. case "(($ac_try" in
  2092. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2093. *) ac_try_echo=$ac_try;;
  2094. esac
  2095. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2096. $as_echo "$ac_try_echo"; } >&5
  2097. (eval "$ac_compile") 2>conftest.err
  2098. ac_status=$?
  2099. if test -s conftest.err; then
  2100. grep -v '^ *+' conftest.err >conftest.er1
  2101. cat conftest.er1 >&5
  2102. mv -f conftest.er1 conftest.err
  2103. fi
  2104. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2105. test $ac_status = 0; } && {
  2106. test -z "$ac_c_werror_flag" ||
  2107. test ! -s conftest.err
  2108. } && test -s conftest.$ac_objext; then :
  2109. ac_retval=0
  2110. else
  2111. $as_echo "$as_me: failed program was:" >&5
  2112. sed 's/^/| /' conftest.$ac_ext >&5
  2113. ac_retval=1
  2114. fi
  2115. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2116. as_fn_set_status $ac_retval
  2117. } # ac_fn_c_try_compile
  2118. # ac_fn_c_try_cpp LINENO
  2119. # ----------------------
  2120. # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
  2121. ac_fn_c_try_cpp ()
  2122. {
  2123. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2124. if { { ac_try="$ac_cpp conftest.$ac_ext"
  2125. case "(($ac_try" in
  2126. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2127. *) ac_try_echo=$ac_try;;
  2128. esac
  2129. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2130. $as_echo "$ac_try_echo"; } >&5
  2131. (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
  2132. ac_status=$?
  2133. if test -s conftest.err; then
  2134. grep -v '^ *+' conftest.err >conftest.er1
  2135. cat conftest.er1 >&5
  2136. mv -f conftest.er1 conftest.err
  2137. fi
  2138. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2139. test $ac_status = 0; } > conftest.i && {
  2140. test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
  2141. test ! -s conftest.err
  2142. }; then :
  2143. ac_retval=0
  2144. else
  2145. $as_echo "$as_me: failed program was:" >&5
  2146. sed 's/^/| /' conftest.$ac_ext >&5
  2147. ac_retval=1
  2148. fi
  2149. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2150. as_fn_set_status $ac_retval
  2151. } # ac_fn_c_try_cpp
  2152. # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
  2153. # -------------------------------------------------------
  2154. # Tests whether HEADER exists, giving a warning if it cannot be compiled using
  2155. # the include files in INCLUDES and setting the cache variable VAR
  2156. # accordingly.
  2157. ac_fn_c_check_header_mongrel ()
  2158. {
  2159. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2160. if eval \${$3+:} false; then :
  2161. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2162. $as_echo_n "checking for $2... " >&6; }
  2163. if eval \${$3+:} false; then :
  2164. $as_echo_n "(cached) " >&6
  2165. fi
  2166. eval ac_res=\$$3
  2167. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2168. $as_echo "$ac_res" >&6; }
  2169. else
  2170. # Is the header compilable?
  2171. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
  2172. $as_echo_n "checking $2 usability... " >&6; }
  2173. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2174. /* end confdefs.h. */
  2175. $4
  2176. #include <$2>
  2177. _ACEOF
  2178. if ac_fn_c_try_compile "$LINENO"; then :
  2179. ac_header_compiler=yes
  2180. else
  2181. ac_header_compiler=no
  2182. fi
  2183. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2184. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
  2185. $as_echo "$ac_header_compiler" >&6; }
  2186. # Is the header present?
  2187. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
  2188. $as_echo_n "checking $2 presence... " >&6; }
  2189. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2190. /* end confdefs.h. */
  2191. #include <$2>
  2192. _ACEOF
  2193. if ac_fn_c_try_cpp "$LINENO"; then :
  2194. ac_header_preproc=yes
  2195. else
  2196. ac_header_preproc=no
  2197. fi
  2198. rm -f conftest.err conftest.i conftest.$ac_ext
  2199. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
  2200. $as_echo "$ac_header_preproc" >&6; }
  2201. # So? What about this header?
  2202. case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
  2203. yes:no: )
  2204. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
  2205. $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
  2206. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2207. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2208. ;;
  2209. no:yes:* )
  2210. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
  2211. $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
  2212. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
  2213. $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
  2214. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
  2215. $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
  2216. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
  2217. $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
  2218. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2219. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2220. ( $as_echo "## ------------------------------------------ ##
  2221. ## Report this to https://issues.asterisk.org ##
  2222. ## ------------------------------------------ ##"
  2223. ) | sed "s/^/$as_me: WARNING: /" >&2
  2224. ;;
  2225. esac
  2226. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2227. $as_echo_n "checking for $2... " >&6; }
  2228. if eval \${$3+:} false; then :
  2229. $as_echo_n "(cached) " >&6
  2230. else
  2231. eval "$3=\$ac_header_compiler"
  2232. fi
  2233. eval ac_res=\$$3
  2234. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2235. $as_echo "$ac_res" >&6; }
  2236. fi
  2237. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2238. } # ac_fn_c_check_header_mongrel
  2239. # ac_fn_c_try_run LINENO
  2240. # ----------------------
  2241. # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
  2242. # that executables *can* be run.
  2243. ac_fn_c_try_run ()
  2244. {
  2245. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2246. if { { ac_try="$ac_link"
  2247. case "(($ac_try" in
  2248. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2249. *) ac_try_echo=$ac_try;;
  2250. esac
  2251. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2252. $as_echo "$ac_try_echo"; } >&5
  2253. (eval "$ac_link") 2>&5
  2254. ac_status=$?
  2255. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2256. test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
  2257. { { case "(($ac_try" in
  2258. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2259. *) ac_try_echo=$ac_try;;
  2260. esac
  2261. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2262. $as_echo "$ac_try_echo"; } >&5
  2263. (eval "$ac_try") 2>&5
  2264. ac_status=$?
  2265. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2266. test $ac_status = 0; }; }; then :
  2267. ac_retval=0
  2268. else
  2269. $as_echo "$as_me: program exited with status $ac_status" >&5
  2270. $as_echo "$as_me: failed program was:" >&5
  2271. sed 's/^/| /' conftest.$ac_ext >&5
  2272. ac_retval=$ac_status
  2273. fi
  2274. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  2275. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2276. as_fn_set_status $ac_retval
  2277. } # ac_fn_c_try_run
  2278. # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
  2279. # -------------------------------------------------------
  2280. # Tests whether HEADER exists and can be compiled using the include files in
  2281. # INCLUDES, setting the cache variable VAR accordingly.
  2282. ac_fn_c_check_header_compile ()
  2283. {
  2284. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2285. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2286. $as_echo_n "checking for $2... " >&6; }
  2287. if eval \${$3+:} false; then :
  2288. $as_echo_n "(cached) " >&6
  2289. else
  2290. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2291. /* end confdefs.h. */
  2292. $4
  2293. #include <$2>
  2294. _ACEOF
  2295. if ac_fn_c_try_compile "$LINENO"; then :
  2296. eval "$3=yes"
  2297. else
  2298. eval "$3=no"
  2299. fi
  2300. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2301. fi
  2302. eval ac_res=\$$3
  2303. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2304. $as_echo "$ac_res" >&6; }
  2305. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2306. } # ac_fn_c_check_header_compile
  2307. # ac_fn_cxx_try_compile LINENO
  2308. # ----------------------------
  2309. # Try to compile conftest.$ac_ext, and return whether this succeeded.
  2310. ac_fn_cxx_try_compile ()
  2311. {
  2312. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2313. rm -f conftest.$ac_objext
  2314. if { { ac_try="$ac_compile"
  2315. case "(($ac_try" in
  2316. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2317. *) ac_try_echo=$ac_try;;
  2318. esac
  2319. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2320. $as_echo "$ac_try_echo"; } >&5
  2321. (eval "$ac_compile") 2>conftest.err
  2322. ac_status=$?
  2323. if test -s conftest.err; then
  2324. grep -v '^ *+' conftest.err >conftest.er1
  2325. cat conftest.er1 >&5
  2326. mv -f conftest.er1 conftest.err
  2327. fi
  2328. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2329. test $ac_status = 0; } && {
  2330. test -z "$ac_cxx_werror_flag" ||
  2331. test ! -s conftest.err
  2332. } && test -s conftest.$ac_objext; then :
  2333. ac_retval=0
  2334. else
  2335. $as_echo "$as_me: failed program was:" >&5
  2336. sed 's/^/| /' conftest.$ac_ext >&5
  2337. ac_retval=1
  2338. fi
  2339. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2340. as_fn_set_status $ac_retval
  2341. } # ac_fn_cxx_try_compile
  2342. # ac_fn_cxx_try_cpp LINENO
  2343. # ------------------------
  2344. # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
  2345. ac_fn_cxx_try_cpp ()
  2346. {
  2347. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2348. if { { ac_try="$ac_cpp conftest.$ac_ext"
  2349. case "(($ac_try" in
  2350. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2351. *) ac_try_echo=$ac_try;;
  2352. esac
  2353. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2354. $as_echo "$ac_try_echo"; } >&5
  2355. (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
  2356. ac_status=$?
  2357. if test -s conftest.err; then
  2358. grep -v '^ *+' conftest.err >conftest.er1
  2359. cat conftest.er1 >&5
  2360. mv -f conftest.er1 conftest.err
  2361. fi
  2362. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2363. test $ac_status = 0; } > conftest.i && {
  2364. test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
  2365. test ! -s conftest.err
  2366. }; then :
  2367. ac_retval=0
  2368. else
  2369. $as_echo "$as_me: failed program was:" >&5
  2370. sed 's/^/| /' conftest.$ac_ext >&5
  2371. ac_retval=1
  2372. fi
  2373. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2374. as_fn_set_status $ac_retval
  2375. } # ac_fn_cxx_try_cpp
  2376. # ac_fn_c_try_link LINENO
  2377. # -----------------------
  2378. # Try to link conftest.$ac_ext, and return whether this succeeded.
  2379. ac_fn_c_try_link ()
  2380. {
  2381. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2382. rm -f conftest.$ac_objext conftest$ac_exeext
  2383. if { { ac_try="$ac_link"
  2384. case "(($ac_try" in
  2385. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2386. *) ac_try_echo=$ac_try;;
  2387. esac
  2388. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2389. $as_echo "$ac_try_echo"; } >&5
  2390. (eval "$ac_link") 2>conftest.err
  2391. ac_status=$?
  2392. if test -s conftest.err; then
  2393. grep -v '^ *+' conftest.err >conftest.er1
  2394. cat conftest.er1 >&5
  2395. mv -f conftest.er1 conftest.err
  2396. fi
  2397. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2398. test $ac_status = 0; } && {
  2399. test -z "$ac_c_werror_flag" ||
  2400. test ! -s conftest.err
  2401. } && test -s conftest$ac_exeext && {
  2402. test "$cross_compiling" = yes ||
  2403. test -x conftest$ac_exeext
  2404. }; then :
  2405. ac_retval=0
  2406. else
  2407. $as_echo "$as_me: failed program was:" >&5
  2408. sed 's/^/| /' conftest.$ac_ext >&5
  2409. ac_retval=1
  2410. fi
  2411. # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
  2412. # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
  2413. # interfere with the next link command; also delete a directory that is
  2414. # left behind by Apple's compiler. We do this before executing the actions.
  2415. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  2416. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2417. as_fn_set_status $ac_retval
  2418. } # ac_fn_c_try_link
  2419. # ac_fn_c_check_func LINENO FUNC VAR
  2420. # ----------------------------------
  2421. # Tests whether FUNC exists, setting the cache variable VAR accordingly
  2422. ac_fn_c_check_func ()
  2423. {
  2424. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2425. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2426. $as_echo_n "checking for $2... " >&6; }
  2427. if eval \${$3+:} false; then :
  2428. $as_echo_n "(cached) " >&6
  2429. else
  2430. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2431. /* end confdefs.h. */
  2432. /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
  2433. For example, HP-UX 11i <limits.h> declares gettimeofday. */
  2434. #define $2 innocuous_$2
  2435. /* System header to define __stub macros and hopefully few prototypes,
  2436. which can conflict with char $2 (); below.
  2437. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  2438. <limits.h> exists even on freestanding compilers. */
  2439. #ifdef __STDC__
  2440. # include <limits.h>
  2441. #else
  2442. # include <assert.h>
  2443. #endif
  2444. #undef $2
  2445. /* Override any GCC internal prototype to avoid an error.
  2446. Use char because int might match the return type of a GCC
  2447. builtin and then its argument prototype would still apply. */
  2448. #ifdef __cplusplus
  2449. extern "C"
  2450. #endif
  2451. char $2 ();
  2452. /* The GNU C library defines this for functions which it implements
  2453. to always fail with ENOSYS. Some functions are actually named
  2454. something starting with __ and the normal name is an alias. */
  2455. #if defined __stub_$2 || defined __stub___$2
  2456. choke me
  2457. #endif
  2458. int
  2459. main ()
  2460. {
  2461. return $2 ();
  2462. ;
  2463. return 0;
  2464. }
  2465. _ACEOF
  2466. if ac_fn_c_try_link "$LINENO"; then :
  2467. eval "$3=yes"
  2468. else
  2469. eval "$3=no"
  2470. fi
  2471. rm -f core conftest.err conftest.$ac_objext \
  2472. conftest$ac_exeext conftest.$ac_ext
  2473. fi
  2474. eval ac_res=\$$3
  2475. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2476. $as_echo "$ac_res" >&6; }
  2477. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2478. } # ac_fn_c_check_func
  2479. # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
  2480. # -------------------------------------------
  2481. # Tests whether TYPE exists after having included INCLUDES, setting cache
  2482. # variable VAR accordingly.
  2483. ac_fn_c_check_type ()
  2484. {
  2485. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2486. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2487. $as_echo_n "checking for $2... " >&6; }
  2488. if eval \${$3+:} false; then :
  2489. $as_echo_n "(cached) " >&6
  2490. else
  2491. eval "$3=no"
  2492. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2493. /* end confdefs.h. */
  2494. $4
  2495. int
  2496. main ()
  2497. {
  2498. if (sizeof ($2))
  2499. return 0;
  2500. ;
  2501. return 0;
  2502. }
  2503. _ACEOF
  2504. if ac_fn_c_try_compile "$LINENO"; then :
  2505. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2506. /* end confdefs.h. */
  2507. $4
  2508. int
  2509. main ()
  2510. {
  2511. if (sizeof (($2)))
  2512. return 0;
  2513. ;
  2514. return 0;
  2515. }
  2516. _ACEOF
  2517. if ac_fn_c_try_compile "$LINENO"; then :
  2518. else
  2519. eval "$3=yes"
  2520. fi
  2521. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2522. fi
  2523. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2524. fi
  2525. eval ac_res=\$$3
  2526. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2527. $as_echo "$ac_res" >&6; }
  2528. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2529. } # ac_fn_c_check_type
  2530. # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
  2531. # ----------------------------------------------------
  2532. # Tries to find if the field MEMBER exists in type AGGR, after including
  2533. # INCLUDES, setting cache variable VAR accordingly.
  2534. ac_fn_c_check_member ()
  2535. {
  2536. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2537. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
  2538. $as_echo_n "checking for $2.$3... " >&6; }
  2539. if eval \${$4+:} false; then :
  2540. $as_echo_n "(cached) " >&6
  2541. else
  2542. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2543. /* end confdefs.h. */
  2544. $5
  2545. int
  2546. main ()
  2547. {
  2548. static $2 ac_aggr;
  2549. if (ac_aggr.$3)
  2550. return 0;
  2551. ;
  2552. return 0;
  2553. }
  2554. _ACEOF
  2555. if ac_fn_c_try_compile "$LINENO"; then :
  2556. eval "$4=yes"
  2557. else
  2558. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2559. /* end confdefs.h. */
  2560. $5
  2561. int
  2562. main ()
  2563. {
  2564. static $2 ac_aggr;
  2565. if (sizeof ac_aggr.$3)
  2566. return 0;
  2567. ;
  2568. return 0;
  2569. }
  2570. _ACEOF
  2571. if ac_fn_c_try_compile "$LINENO"; then :
  2572. eval "$4=yes"
  2573. else
  2574. eval "$4=no"
  2575. fi
  2576. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2577. fi
  2578. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2579. fi
  2580. eval ac_res=\$$4
  2581. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2582. $as_echo "$ac_res" >&6; }
  2583. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2584. } # ac_fn_c_check_member
  2585. # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
  2586. # --------------------------------------------
  2587. # Tries to find the compile-time value of EXPR in a program that includes
  2588. # INCLUDES, setting VAR accordingly. Returns whether the value could be
  2589. # computed
  2590. ac_fn_c_compute_int ()
  2591. {
  2592. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2593. if test "$cross_compiling" = yes; then
  2594. # Depending upon the size, compute the lo and hi bounds.
  2595. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2596. /* end confdefs.h. */
  2597. $4
  2598. int
  2599. main ()
  2600. {
  2601. static int test_array [1 - 2 * !(($2) >= 0)];
  2602. test_array [0] = 0;
  2603. return test_array [0];
  2604. ;
  2605. return 0;
  2606. }
  2607. _ACEOF
  2608. if ac_fn_c_try_compile "$LINENO"; then :
  2609. ac_lo=0 ac_mid=0
  2610. while :; do
  2611. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2612. /* end confdefs.h. */
  2613. $4
  2614. int
  2615. main ()
  2616. {
  2617. static int test_array [1 - 2 * !(($2) <= $ac_mid)];
  2618. test_array [0] = 0;
  2619. return test_array [0];
  2620. ;
  2621. return 0;
  2622. }
  2623. _ACEOF
  2624. if ac_fn_c_try_compile "$LINENO"; then :
  2625. ac_hi=$ac_mid; break
  2626. else
  2627. as_fn_arith $ac_mid + 1 && ac_lo=$as_val
  2628. if test $ac_lo -le $ac_mid; then
  2629. ac_lo= ac_hi=
  2630. break
  2631. fi
  2632. as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
  2633. fi
  2634. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2635. done
  2636. else
  2637. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2638. /* end confdefs.h. */
  2639. $4
  2640. int
  2641. main ()
  2642. {
  2643. static int test_array [1 - 2 * !(($2) < 0)];
  2644. test_array [0] = 0;
  2645. return test_array [0];
  2646. ;
  2647. return 0;
  2648. }
  2649. _ACEOF
  2650. if ac_fn_c_try_compile "$LINENO"; then :
  2651. ac_hi=-1 ac_mid=-1
  2652. while :; do
  2653. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2654. /* end confdefs.h. */
  2655. $4
  2656. int
  2657. main ()
  2658. {
  2659. static int test_array [1 - 2 * !(($2) >= $ac_mid)];
  2660. test_array [0] = 0;
  2661. return test_array [0];
  2662. ;
  2663. return 0;
  2664. }
  2665. _ACEOF
  2666. if ac_fn_c_try_compile "$LINENO"; then :
  2667. ac_lo=$ac_mid; break
  2668. else
  2669. as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
  2670. if test $ac_mid -le $ac_hi; then
  2671. ac_lo= ac_hi=
  2672. break
  2673. fi
  2674. as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
  2675. fi
  2676. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2677. done
  2678. else
  2679. ac_lo= ac_hi=
  2680. fi
  2681. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2682. fi
  2683. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2684. # Binary search between lo and hi bounds.
  2685. while test "x$ac_lo" != "x$ac_hi"; do
  2686. as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
  2687. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2688. /* end confdefs.h. */
  2689. $4
  2690. int
  2691. main ()
  2692. {
  2693. static int test_array [1 - 2 * !(($2) <= $ac_mid)];
  2694. test_array [0] = 0;
  2695. return test_array [0];
  2696. ;
  2697. return 0;
  2698. }
  2699. _ACEOF
  2700. if ac_fn_c_try_compile "$LINENO"; then :
  2701. ac_hi=$ac_mid
  2702. else
  2703. as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
  2704. fi
  2705. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2706. done
  2707. case $ac_lo in #((
  2708. ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
  2709. '') ac_retval=1 ;;
  2710. esac
  2711. else
  2712. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2713. /* end confdefs.h. */
  2714. $4
  2715. static long int longval () { return $2; }
  2716. static unsigned long int ulongval () { return $2; }
  2717. #include <stdio.h>
  2718. #include <stdlib.h>
  2719. int
  2720. main ()
  2721. {
  2722. FILE *f = fopen ("conftest.val", "w");
  2723. if (! f)
  2724. return 1;
  2725. if (($2) < 0)
  2726. {
  2727. long int i = longval ();
  2728. if (i != ($2))
  2729. return 1;
  2730. fprintf (f, "%ld", i);
  2731. }
  2732. else
  2733. {
  2734. unsigned long int i = ulongval ();
  2735. if (i != ($2))
  2736. return 1;
  2737. fprintf (f, "%lu", i);
  2738. }
  2739. /* Do not output a trailing newline, as this causes \r\n confusion
  2740. on some platforms. */
  2741. return ferror (f) || fclose (f) != 0;
  2742. ;
  2743. return 0;
  2744. }
  2745. _ACEOF
  2746. if ac_fn_c_try_run "$LINENO"; then :
  2747. echo >>conftest.val; read $3 <conftest.val; ac_retval=0
  2748. else
  2749. ac_retval=1
  2750. fi
  2751. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  2752. conftest.$ac_objext conftest.beam conftest.$ac_ext
  2753. rm -f conftest.val
  2754. fi
  2755. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2756. as_fn_set_status $ac_retval
  2757. } # ac_fn_c_compute_int
  2758. # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
  2759. # ---------------------------------------------------------
  2760. # Tests whether HEADER exists, giving a warning if it cannot be compiled using
  2761. # the include files in INCLUDES and setting the cache variable VAR
  2762. # accordingly.
  2763. ac_fn_cxx_check_header_mongrel ()
  2764. {
  2765. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2766. if eval \${$3+:} false; then :
  2767. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2768. $as_echo_n "checking for $2... " >&6; }
  2769. if eval \${$3+:} false; then :
  2770. $as_echo_n "(cached) " >&6
  2771. fi
  2772. eval ac_res=\$$3
  2773. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2774. $as_echo "$ac_res" >&6; }
  2775. else
  2776. # Is the header compilable?
  2777. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
  2778. $as_echo_n "checking $2 usability... " >&6; }
  2779. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2780. /* end confdefs.h. */
  2781. $4
  2782. #include <$2>
  2783. _ACEOF
  2784. if ac_fn_cxx_try_compile "$LINENO"; then :
  2785. ac_header_compiler=yes
  2786. else
  2787. ac_header_compiler=no
  2788. fi
  2789. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2790. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
  2791. $as_echo "$ac_header_compiler" >&6; }
  2792. # Is the header present?
  2793. { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
  2794. $as_echo_n "checking $2 presence... " >&6; }
  2795. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2796. /* end confdefs.h. */
  2797. #include <$2>
  2798. _ACEOF
  2799. if ac_fn_cxx_try_cpp "$LINENO"; then :
  2800. ac_header_preproc=yes
  2801. else
  2802. ac_header_preproc=no
  2803. fi
  2804. rm -f conftest.err conftest.i conftest.$ac_ext
  2805. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
  2806. $as_echo "$ac_header_preproc" >&6; }
  2807. # So? What about this header?
  2808. case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
  2809. yes:no: )
  2810. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
  2811. $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
  2812. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2813. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2814. ;;
  2815. no:yes:* )
  2816. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
  2817. $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
  2818. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
  2819. $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
  2820. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
  2821. $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
  2822. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
  2823. $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
  2824. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
  2825. $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
  2826. ( $as_echo "## ------------------------------------------ ##
  2827. ## Report this to https://issues.asterisk.org ##
  2828. ## ------------------------------------------ ##"
  2829. ) | sed "s/^/$as_me: WARNING: /" >&2
  2830. ;;
  2831. esac
  2832. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2833. $as_echo_n "checking for $2... " >&6; }
  2834. if eval \${$3+:} false; then :
  2835. $as_echo_n "(cached) " >&6
  2836. else
  2837. eval "$3=\$ac_header_compiler"
  2838. fi
  2839. eval ac_res=\$$3
  2840. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2841. $as_echo "$ac_res" >&6; }
  2842. fi
  2843. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2844. } # ac_fn_cxx_check_header_mongrel
  2845. # ac_fn_cxx_try_link LINENO
  2846. # -------------------------
  2847. # Try to link conftest.$ac_ext, and return whether this succeeded.
  2848. ac_fn_cxx_try_link ()
  2849. {
  2850. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2851. rm -f conftest.$ac_objext conftest$ac_exeext
  2852. if { { ac_try="$ac_link"
  2853. case "(($ac_try" in
  2854. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  2855. *) ac_try_echo=$ac_try;;
  2856. esac
  2857. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  2858. $as_echo "$ac_try_echo"; } >&5
  2859. (eval "$ac_link") 2>conftest.err
  2860. ac_status=$?
  2861. if test -s conftest.err; then
  2862. grep -v '^ *+' conftest.err >conftest.er1
  2863. cat conftest.er1 >&5
  2864. mv -f conftest.er1 conftest.err
  2865. fi
  2866. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  2867. test $ac_status = 0; } && {
  2868. test -z "$ac_cxx_werror_flag" ||
  2869. test ! -s conftest.err
  2870. } && test -s conftest$ac_exeext && {
  2871. test "$cross_compiling" = yes ||
  2872. test -x conftest$ac_exeext
  2873. }; then :
  2874. ac_retval=0
  2875. else
  2876. $as_echo "$as_me: failed program was:" >&5
  2877. sed 's/^/| /' conftest.$ac_ext >&5
  2878. ac_retval=1
  2879. fi
  2880. # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
  2881. # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
  2882. # interfere with the next link command; also delete a directory that is
  2883. # left behind by Apple's compiler. We do this before executing the actions.
  2884. rm -rf conftest.dSYM conftest_ipa8_conftest.oo
  2885. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2886. as_fn_set_status $ac_retval
  2887. } # ac_fn_cxx_try_link
  2888. # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES
  2889. # ---------------------------------------------------------
  2890. # Tests whether HEADER exists and can be compiled using the include files in
  2891. # INCLUDES, setting the cache variable VAR accordingly.
  2892. ac_fn_cxx_check_header_compile ()
  2893. {
  2894. as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  2895. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
  2896. $as_echo_n "checking for $2... " >&6; }
  2897. if eval \${$3+:} false; then :
  2898. $as_echo_n "(cached) " >&6
  2899. else
  2900. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  2901. /* end confdefs.h. */
  2902. $4
  2903. #include <$2>
  2904. _ACEOF
  2905. if ac_fn_cxx_try_compile "$LINENO"; then :
  2906. eval "$3=yes"
  2907. else
  2908. eval "$3=no"
  2909. fi
  2910. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  2911. fi
  2912. eval ac_res=\$$3
  2913. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  2914. $as_echo "$ac_res" >&6; }
  2915. eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
  2916. } # ac_fn_cxx_check_header_compile
  2917. cat >config.log <<_ACEOF
  2918. This file contains any messages produced by compilers while
  2919. running configure, to aid debugging if configure makes a mistake.
  2920. It was created by asterisk $as_me trunk, which was
  2921. generated by GNU Autoconf 2.69. Invocation command line was
  2922. $ $0 $@
  2923. _ACEOF
  2924. exec 5>>config.log
  2925. {
  2926. cat <<_ASUNAME
  2927. ## --------- ##
  2928. ## Platform. ##
  2929. ## --------- ##
  2930. hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
  2931. uname -m = `(uname -m) 2>/dev/null || echo unknown`
  2932. uname -r = `(uname -r) 2>/dev/null || echo unknown`
  2933. uname -s = `(uname -s) 2>/dev/null || echo unknown`
  2934. uname -v = `(uname -v) 2>/dev/null || echo unknown`
  2935. /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
  2936. /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
  2937. /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
  2938. /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
  2939. /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
  2940. /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
  2941. /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
  2942. /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
  2943. /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
  2944. _ASUNAME
  2945. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  2946. for as_dir in $PATH
  2947. do
  2948. IFS=$as_save_IFS
  2949. test -z "$as_dir" && as_dir=.
  2950. $as_echo "PATH: $as_dir"
  2951. done
  2952. IFS=$as_save_IFS
  2953. } >&5
  2954. cat >&5 <<_ACEOF
  2955. ## ----------- ##
  2956. ## Core tests. ##
  2957. ## ----------- ##
  2958. _ACEOF
  2959. # Keep a trace of the command line.
  2960. # Strip out --no-create and --no-recursion so they do not pile up.
  2961. # Strip out --silent because we don't want to record it for future runs.
  2962. # Also quote any args containing shell meta-characters.
  2963. # Make two passes to allow for proper duplicate-argument suppression.
  2964. ac_configure_args=
  2965. ac_configure_args0=
  2966. ac_configure_args1=
  2967. ac_must_keep_next=false
  2968. for ac_pass in 1 2
  2969. do
  2970. for ac_arg
  2971. do
  2972. case $ac_arg in
  2973. -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
  2974. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  2975. | -silent | --silent | --silen | --sile | --sil)
  2976. continue ;;
  2977. *\'*)
  2978. ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
  2979. esac
  2980. case $ac_pass in
  2981. 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
  2982. 2)
  2983. as_fn_append ac_configure_args1 " '$ac_arg'"
  2984. if test $ac_must_keep_next = true; then
  2985. ac_must_keep_next=false # Got value, back to normal.
  2986. else
  2987. case $ac_arg in
  2988. *=* | --config-cache | -C | -disable-* | --disable-* \
  2989. | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
  2990. | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
  2991. | -with-* | --with-* | -without-* | --without-* | --x)
  2992. case "$ac_configure_args0 " in
  2993. "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
  2994. esac
  2995. ;;
  2996. -* ) ac_must_keep_next=true ;;
  2997. esac
  2998. fi
  2999. as_fn_append ac_configure_args " '$ac_arg'"
  3000. ;;
  3001. esac
  3002. done
  3003. done
  3004. { ac_configure_args0=; unset ac_configure_args0;}
  3005. { ac_configure_args1=; unset ac_configure_args1;}
  3006. # When interrupted or exit'd, cleanup temporary files, and complete
  3007. # config.log. We remove comments because anyway the quotes in there
  3008. # would cause problems or look ugly.
  3009. # WARNING: Use '\'' to represent an apostrophe within the trap.
  3010. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
  3011. trap 'exit_status=$?
  3012. # Save into config.log some information that might help in debugging.
  3013. {
  3014. echo
  3015. $as_echo "## ---------------- ##
  3016. ## Cache variables. ##
  3017. ## ---------------- ##"
  3018. echo
  3019. # The following way of writing the cache mishandles newlines in values,
  3020. (
  3021. for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
  3022. eval ac_val=\$$ac_var
  3023. case $ac_val in #(
  3024. *${as_nl}*)
  3025. case $ac_var in #(
  3026. *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
  3027. $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
  3028. esac
  3029. case $ac_var in #(
  3030. _ | IFS | as_nl) ;; #(
  3031. BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
  3032. *) { eval $ac_var=; unset $ac_var;} ;;
  3033. esac ;;
  3034. esac
  3035. done
  3036. (set) 2>&1 |
  3037. case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
  3038. *${as_nl}ac_space=\ *)
  3039. sed -n \
  3040. "s/'\''/'\''\\\\'\'''\''/g;
  3041. s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
  3042. ;; #(
  3043. *)
  3044. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
  3045. ;;
  3046. esac |
  3047. sort
  3048. )
  3049. echo
  3050. $as_echo "## ----------------- ##
  3051. ## Output variables. ##
  3052. ## ----------------- ##"
  3053. echo
  3054. for ac_var in $ac_subst_vars
  3055. do
  3056. eval ac_val=\$$ac_var
  3057. case $ac_val in
  3058. *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
  3059. esac
  3060. $as_echo "$ac_var='\''$ac_val'\''"
  3061. done | sort
  3062. echo
  3063. if test -n "$ac_subst_files"; then
  3064. $as_echo "## ------------------- ##
  3065. ## File substitutions. ##
  3066. ## ------------------- ##"
  3067. echo
  3068. for ac_var in $ac_subst_files
  3069. do
  3070. eval ac_val=\$$ac_var
  3071. case $ac_val in
  3072. *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
  3073. esac
  3074. $as_echo "$ac_var='\''$ac_val'\''"
  3075. done | sort
  3076. echo
  3077. fi
  3078. if test -s confdefs.h; then
  3079. $as_echo "## ----------- ##
  3080. ## confdefs.h. ##
  3081. ## ----------- ##"
  3082. echo
  3083. cat confdefs.h
  3084. echo
  3085. fi
  3086. test "$ac_signal" != 0 &&
  3087. $as_echo "$as_me: caught signal $ac_signal"
  3088. $as_echo "$as_me: exit $exit_status"
  3089. } >&5
  3090. rm -f core *.core core.conftest.* &&
  3091. rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
  3092. exit $exit_status
  3093. ' 0
  3094. for ac_signal in 1 2 13 15; do
  3095. trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
  3096. done
  3097. ac_signal=0
  3098. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  3099. rm -f -r conftest* confdefs.h
  3100. $as_echo "/* confdefs.h */" > confdefs.h
  3101. # Predefined preprocessor variables.
  3102. cat >>confdefs.h <<_ACEOF
  3103. #define PACKAGE_NAME "$PACKAGE_NAME"
  3104. _ACEOF
  3105. cat >>confdefs.h <<_ACEOF
  3106. #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
  3107. _ACEOF
  3108. cat >>confdefs.h <<_ACEOF
  3109. #define PACKAGE_VERSION "$PACKAGE_VERSION"
  3110. _ACEOF
  3111. cat >>confdefs.h <<_ACEOF
  3112. #define PACKAGE_STRING "$PACKAGE_STRING"
  3113. _ACEOF
  3114. cat >>confdefs.h <<_ACEOF
  3115. #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
  3116. _ACEOF
  3117. cat >>confdefs.h <<_ACEOF
  3118. #define PACKAGE_URL "$PACKAGE_URL"
  3119. _ACEOF
  3120. # Let the site file select an alternate cache file if it wants to.
  3121. # Prefer an explicitly selected file to automatically selected ones.
  3122. ac_site_file1=NONE
  3123. ac_site_file2=NONE
  3124. if test -n "$CONFIG_SITE"; then
  3125. # We do not want a PATH search for config.site.
  3126. case $CONFIG_SITE in #((
  3127. -*) ac_site_file1=./$CONFIG_SITE;;
  3128. */*) ac_site_file1=$CONFIG_SITE;;
  3129. *) ac_site_file1=./$CONFIG_SITE;;
  3130. esac
  3131. elif test "x$prefix" != xNONE; then
  3132. ac_site_file1=$prefix/share/config.site
  3133. ac_site_file2=$prefix/etc/config.site
  3134. else
  3135. ac_site_file1=$ac_default_prefix/share/config.site
  3136. ac_site_file2=$ac_default_prefix/etc/config.site
  3137. fi
  3138. for ac_site_file in "$ac_site_file1" "$ac_site_file2"
  3139. do
  3140. test "x$ac_site_file" = xNONE && continue
  3141. if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
  3142. { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
  3143. $as_echo "$as_me: loading site script $ac_site_file" >&6;}
  3144. sed 's/^/| /' "$ac_site_file" >&5
  3145. . "$ac_site_file" \
  3146. || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3147. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3148. as_fn_error $? "failed to load site script $ac_site_file
  3149. See \`config.log' for more details" "$LINENO" 5; }
  3150. fi
  3151. done
  3152. if test -r "$cache_file"; then
  3153. # Some versions of bash will fail to source /dev/null (special files
  3154. # actually), so we avoid doing that. DJGPP emulates it as a regular file.
  3155. if test /dev/null != "$cache_file" && test -f "$cache_file"; then
  3156. { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
  3157. $as_echo "$as_me: loading cache $cache_file" >&6;}
  3158. case $cache_file in
  3159. [\\/]* | ?:[\\/]* ) . "$cache_file";;
  3160. *) . "./$cache_file";;
  3161. esac
  3162. fi
  3163. else
  3164. { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
  3165. $as_echo "$as_me: creating cache $cache_file" >&6;}
  3166. >$cache_file
  3167. fi
  3168. as_fn_append ac_header_list " stdlib.h"
  3169. as_fn_append ac_header_list " unistd.h"
  3170. as_fn_append ac_header_list " sys/param.h"
  3171. as_fn_append ac_header_list " utime.h"
  3172. # Check that the precious variables saved in the cache have kept the same
  3173. # value.
  3174. ac_cache_corrupted=false
  3175. for ac_var in $ac_precious_vars; do
  3176. eval ac_old_set=\$ac_cv_env_${ac_var}_set
  3177. eval ac_new_set=\$ac_env_${ac_var}_set
  3178. eval ac_old_val=\$ac_cv_env_${ac_var}_value
  3179. eval ac_new_val=\$ac_env_${ac_var}_value
  3180. case $ac_old_set,$ac_new_set in
  3181. set,)
  3182. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
  3183. $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
  3184. ac_cache_corrupted=: ;;
  3185. ,set)
  3186. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
  3187. $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
  3188. ac_cache_corrupted=: ;;
  3189. ,);;
  3190. *)
  3191. if test "x$ac_old_val" != "x$ac_new_val"; then
  3192. # differences in whitespace do not lead to failure.
  3193. ac_old_val_w=`echo x $ac_old_val`
  3194. ac_new_val_w=`echo x $ac_new_val`
  3195. if test "$ac_old_val_w" != "$ac_new_val_w"; then
  3196. { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
  3197. $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
  3198. ac_cache_corrupted=:
  3199. else
  3200. { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
  3201. $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
  3202. eval $ac_var=\$ac_old_val
  3203. fi
  3204. { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
  3205. $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
  3206. { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
  3207. $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
  3208. fi;;
  3209. esac
  3210. # Pass precious variables to config.status.
  3211. if test "$ac_new_set" = set; then
  3212. case $ac_new_val in
  3213. *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
  3214. *) ac_arg=$ac_var=$ac_new_val ;;
  3215. esac
  3216. case " $ac_configure_args " in
  3217. *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
  3218. *) as_fn_append ac_configure_args " '$ac_arg'" ;;
  3219. esac
  3220. fi
  3221. done
  3222. if $ac_cache_corrupted; then
  3223. { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3224. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3225. { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
  3226. $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
  3227. as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
  3228. fi
  3229. ## -------------------- ##
  3230. ## Main body of script. ##
  3231. ## -------------------- ##
  3232. ac_ext=c
  3233. ac_cpp='$CPP $CPPFLAGS'
  3234. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3235. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3236. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3237. # cross-compile macros
  3238. ac_aux_dir=
  3239. for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
  3240. if test -f "$ac_dir/install-sh"; then
  3241. ac_aux_dir=$ac_dir
  3242. ac_install_sh="$ac_aux_dir/install-sh -c"
  3243. break
  3244. elif test -f "$ac_dir/install.sh"; then
  3245. ac_aux_dir=$ac_dir
  3246. ac_install_sh="$ac_aux_dir/install.sh -c"
  3247. break
  3248. elif test -f "$ac_dir/shtool"; then
  3249. ac_aux_dir=$ac_dir
  3250. ac_install_sh="$ac_aux_dir/shtool install -c"
  3251. break
  3252. fi
  3253. done
  3254. if test -z "$ac_aux_dir"; then
  3255. as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
  3256. fi
  3257. # These three variables are undocumented and unsupported,
  3258. # and are intended to be withdrawn in a future Autoconf release.
  3259. # They can cause serious problems if a builder's source tree is in a directory
  3260. # whose full name contains unusual characters.
  3261. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
  3262. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
  3263. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
  3264. # Make sure we can run config.sub.
  3265. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
  3266. as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
  3267. { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
  3268. $as_echo_n "checking build system type... " >&6; }
  3269. if ${ac_cv_build+:} false; then :
  3270. $as_echo_n "(cached) " >&6
  3271. else
  3272. ac_build_alias=$build_alias
  3273. test "x$ac_build_alias" = x &&
  3274. ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
  3275. test "x$ac_build_alias" = x &&
  3276. as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
  3277. ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
  3278. as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
  3279. fi
  3280. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
  3281. $as_echo "$ac_cv_build" >&6; }
  3282. case $ac_cv_build in
  3283. *-*-*) ;;
  3284. *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
  3285. esac
  3286. build=$ac_cv_build
  3287. ac_save_IFS=$IFS; IFS='-'
  3288. set x $ac_cv_build
  3289. shift
  3290. build_cpu=$1
  3291. build_vendor=$2
  3292. shift; shift
  3293. # Remember, the first character of IFS is used to create $*,
  3294. # except with old shells:
  3295. build_os=$*
  3296. IFS=$ac_save_IFS
  3297. case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
  3298. { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
  3299. $as_echo_n "checking host system type... " >&6; }
  3300. if ${ac_cv_host+:} false; then :
  3301. $as_echo_n "(cached) " >&6
  3302. else
  3303. if test "x$host_alias" = x; then
  3304. ac_cv_host=$ac_cv_build
  3305. else
  3306. ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
  3307. as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
  3308. fi
  3309. fi
  3310. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
  3311. $as_echo "$ac_cv_host" >&6; }
  3312. case $ac_cv_host in
  3313. *-*-*) ;;
  3314. *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
  3315. esac
  3316. host=$ac_cv_host
  3317. ac_save_IFS=$IFS; IFS='-'
  3318. set x $ac_cv_host
  3319. shift
  3320. host_cpu=$1
  3321. host_vendor=$2
  3322. shift; shift
  3323. # Remember, the first character of IFS is used to create $*,
  3324. # except with old shells:
  3325. host_os=$*
  3326. IFS=$ac_save_IFS
  3327. case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
  3328. # check existence of the package
  3329. ac_aux_dir=
  3330. for ac_dir in `pwd` "$srcdir"/`pwd`; do
  3331. if test -f "$ac_dir/install-sh"; then
  3332. ac_aux_dir=$ac_dir
  3333. ac_install_sh="$ac_aux_dir/install-sh -c"
  3334. break
  3335. elif test -f "$ac_dir/install.sh"; then
  3336. ac_aux_dir=$ac_dir
  3337. ac_install_sh="$ac_aux_dir/install.sh -c"
  3338. break
  3339. elif test -f "$ac_dir/shtool"; then
  3340. ac_aux_dir=$ac_dir
  3341. ac_install_sh="$ac_aux_dir/shtool install -c"
  3342. break
  3343. fi
  3344. done
  3345. if test -z "$ac_aux_dir"; then
  3346. as_fn_error $? "cannot find install-sh, install.sh, or shtool in \`pwd\` \"$srcdir\"/\`pwd\`" "$LINENO" 5
  3347. fi
  3348. # These three variables are undocumented and unsupported,
  3349. # and are intended to be withdrawn in a future Autoconf release.
  3350. # They can cause serious problems if a builder's source tree is in a directory
  3351. # whose full name contains unusual characters.
  3352. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
  3353. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
  3354. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
  3355. # preserve any CFLAGS or LDFLAGS that may be set
  3356. # NOTE: This must be done before calling any macros that end up
  3357. # calling AC_PROG_CC or the like, since they will set a default
  3358. # set of CFLAGS ("-g -O2") if the user did not supply any, and
  3359. # we don't want those default flags to be carried over into the
  3360. # rest of the build system since we have other means of controlling
  3361. # debugging symbol generation and optimization.
  3362. CONFIG_CFLAGS="${CFLAGS}"
  3363. CONFIG_LDFLAGS="${LDFLAGS}"
  3364. # specify output header file
  3365. ac_config_headers="$ac_config_headers include/asterisk/autoconfig.h"
  3366. # Note: AC_PROG_CC *must* be specified before AC_USE_SYSTEM_EXTENSIONS or any
  3367. # other macro that uses the C compiler, or the default order will be used.
  3368. ac_ext=c
  3369. ac_cpp='$CPP $CPPFLAGS'
  3370. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3371. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3372. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3373. if test -n "$ac_tool_prefix"; then
  3374. for ac_prog in gcc cc
  3375. do
  3376. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  3377. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  3378. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3379. $as_echo_n "checking for $ac_word... " >&6; }
  3380. if ${ac_cv_prog_CC+:} false; then :
  3381. $as_echo_n "(cached) " >&6
  3382. else
  3383. if test -n "$CC"; then
  3384. ac_cv_prog_CC="$CC" # Let the user override the test.
  3385. else
  3386. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3387. for as_dir in $PATH
  3388. do
  3389. IFS=$as_save_IFS
  3390. test -z "$as_dir" && as_dir=.
  3391. for ac_exec_ext in '' $ac_executable_extensions; do
  3392. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3393. ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
  3394. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3395. break 2
  3396. fi
  3397. done
  3398. done
  3399. IFS=$as_save_IFS
  3400. fi
  3401. fi
  3402. CC=$ac_cv_prog_CC
  3403. if test -n "$CC"; then
  3404. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  3405. $as_echo "$CC" >&6; }
  3406. else
  3407. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3408. $as_echo "no" >&6; }
  3409. fi
  3410. test -n "$CC" && break
  3411. done
  3412. fi
  3413. if test -z "$CC"; then
  3414. ac_ct_CC=$CC
  3415. for ac_prog in gcc cc
  3416. do
  3417. # Extract the first word of "$ac_prog", so it can be a program name with args.
  3418. set dummy $ac_prog; ac_word=$2
  3419. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  3420. $as_echo_n "checking for $ac_word... " >&6; }
  3421. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  3422. $as_echo_n "(cached) " >&6
  3423. else
  3424. if test -n "$ac_ct_CC"; then
  3425. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  3426. else
  3427. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3428. for as_dir in $PATH
  3429. do
  3430. IFS=$as_save_IFS
  3431. test -z "$as_dir" && as_dir=.
  3432. for ac_exec_ext in '' $ac_executable_extensions; do
  3433. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  3434. ac_cv_prog_ac_ct_CC="$ac_prog"
  3435. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  3436. break 2
  3437. fi
  3438. done
  3439. done
  3440. IFS=$as_save_IFS
  3441. fi
  3442. fi
  3443. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  3444. if test -n "$ac_ct_CC"; then
  3445. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  3446. $as_echo "$ac_ct_CC" >&6; }
  3447. else
  3448. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3449. $as_echo "no" >&6; }
  3450. fi
  3451. test -n "$ac_ct_CC" && break
  3452. done
  3453. if test "x$ac_ct_CC" = x; then
  3454. CC=""
  3455. else
  3456. case $cross_compiling:$ac_tool_warned in
  3457. yes:)
  3458. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  3459. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  3460. ac_tool_warned=yes ;;
  3461. esac
  3462. CC=$ac_ct_CC
  3463. fi
  3464. fi
  3465. test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3466. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3467. as_fn_error $? "no acceptable C compiler found in \$PATH
  3468. See \`config.log' for more details" "$LINENO" 5; }
  3469. # Provide some information about the compiler.
  3470. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
  3471. set X $ac_compile
  3472. ac_compiler=$2
  3473. for ac_option in --version -v -V -qversion; do
  3474. { { ac_try="$ac_compiler $ac_option >&5"
  3475. case "(($ac_try" in
  3476. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3477. *) ac_try_echo=$ac_try;;
  3478. esac
  3479. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3480. $as_echo "$ac_try_echo"; } >&5
  3481. (eval "$ac_compiler $ac_option >&5") 2>conftest.err
  3482. ac_status=$?
  3483. if test -s conftest.err; then
  3484. sed '10a\
  3485. ... rest of stderr output deleted ...
  3486. 10q' conftest.err >conftest.er1
  3487. cat conftest.er1 >&5
  3488. fi
  3489. rm -f conftest.er1 conftest.err
  3490. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3491. test $ac_status = 0; }
  3492. done
  3493. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3494. /* end confdefs.h. */
  3495. int
  3496. main ()
  3497. {
  3498. ;
  3499. return 0;
  3500. }
  3501. _ACEOF
  3502. ac_clean_files_save=$ac_clean_files
  3503. ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
  3504. # Try to create an executable without -o first, disregard a.out.
  3505. # It will help us diagnose broken compilers, and finding out an intuition
  3506. # of exeext.
  3507. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
  3508. $as_echo_n "checking whether the C compiler works... " >&6; }
  3509. ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
  3510. # The possible output files:
  3511. ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
  3512. ac_rmfiles=
  3513. for ac_file in $ac_files
  3514. do
  3515. case $ac_file in
  3516. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
  3517. * ) ac_rmfiles="$ac_rmfiles $ac_file";;
  3518. esac
  3519. done
  3520. rm -f $ac_rmfiles
  3521. if { { ac_try="$ac_link_default"
  3522. case "(($ac_try" in
  3523. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3524. *) ac_try_echo=$ac_try;;
  3525. esac
  3526. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3527. $as_echo "$ac_try_echo"; } >&5
  3528. (eval "$ac_link_default") 2>&5
  3529. ac_status=$?
  3530. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3531. test $ac_status = 0; }; then :
  3532. # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
  3533. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
  3534. # in a Makefile. We should not override ac_cv_exeext if it was cached,
  3535. # so that the user can short-circuit this test for compilers unknown to
  3536. # Autoconf.
  3537. for ac_file in $ac_files ''
  3538. do
  3539. test -f "$ac_file" || continue
  3540. case $ac_file in
  3541. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
  3542. ;;
  3543. [ab].out )
  3544. # We found the default executable, but exeext='' is most
  3545. # certainly right.
  3546. break;;
  3547. *.* )
  3548. if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
  3549. then :; else
  3550. ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
  3551. fi
  3552. # We set ac_cv_exeext here because the later test for it is not
  3553. # safe: cross compilers may not add the suffix if given an `-o'
  3554. # argument, so we may need to know it at that point already.
  3555. # Even if this section looks crufty: it has the advantage of
  3556. # actually working.
  3557. break;;
  3558. * )
  3559. break;;
  3560. esac
  3561. done
  3562. test "$ac_cv_exeext" = no && ac_cv_exeext=
  3563. else
  3564. ac_file=''
  3565. fi
  3566. if test -z "$ac_file"; then :
  3567. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  3568. $as_echo "no" >&6; }
  3569. $as_echo "$as_me: failed program was:" >&5
  3570. sed 's/^/| /' conftest.$ac_ext >&5
  3571. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3572. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3573. as_fn_error 77 "C compiler cannot create executables
  3574. See \`config.log' for more details" "$LINENO" 5; }
  3575. else
  3576. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  3577. $as_echo "yes" >&6; }
  3578. fi
  3579. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
  3580. $as_echo_n "checking for C compiler default output file name... " >&6; }
  3581. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
  3582. $as_echo "$ac_file" >&6; }
  3583. ac_exeext=$ac_cv_exeext
  3584. rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
  3585. ac_clean_files=$ac_clean_files_save
  3586. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
  3587. $as_echo_n "checking for suffix of executables... " >&6; }
  3588. if { { ac_try="$ac_link"
  3589. case "(($ac_try" in
  3590. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3591. *) ac_try_echo=$ac_try;;
  3592. esac
  3593. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3594. $as_echo "$ac_try_echo"; } >&5
  3595. (eval "$ac_link") 2>&5
  3596. ac_status=$?
  3597. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3598. test $ac_status = 0; }; then :
  3599. # If both `conftest.exe' and `conftest' are `present' (well, observable)
  3600. # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
  3601. # work properly (i.e., refer to `conftest.exe'), while it won't with
  3602. # `rm'.
  3603. for ac_file in conftest.exe conftest conftest.*; do
  3604. test -f "$ac_file" || continue
  3605. case $ac_file in
  3606. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
  3607. *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
  3608. break;;
  3609. * ) break;;
  3610. esac
  3611. done
  3612. else
  3613. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3614. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3615. as_fn_error $? "cannot compute suffix of executables: cannot compile and link
  3616. See \`config.log' for more details" "$LINENO" 5; }
  3617. fi
  3618. rm -f conftest conftest$ac_cv_exeext
  3619. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
  3620. $as_echo "$ac_cv_exeext" >&6; }
  3621. rm -f conftest.$ac_ext
  3622. EXEEXT=$ac_cv_exeext
  3623. ac_exeext=$EXEEXT
  3624. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3625. /* end confdefs.h. */
  3626. #include <stdio.h>
  3627. int
  3628. main ()
  3629. {
  3630. FILE *f = fopen ("conftest.out", "w");
  3631. return ferror (f) || fclose (f) != 0;
  3632. ;
  3633. return 0;
  3634. }
  3635. _ACEOF
  3636. ac_clean_files="$ac_clean_files conftest.out"
  3637. # Check that the compiler produces executables we can run. If not, either
  3638. # the compiler is broken, or we cross compile.
  3639. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
  3640. $as_echo_n "checking whether we are cross compiling... " >&6; }
  3641. if test "$cross_compiling" != yes; then
  3642. { { ac_try="$ac_link"
  3643. case "(($ac_try" in
  3644. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3645. *) ac_try_echo=$ac_try;;
  3646. esac
  3647. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3648. $as_echo "$ac_try_echo"; } >&5
  3649. (eval "$ac_link") 2>&5
  3650. ac_status=$?
  3651. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3652. test $ac_status = 0; }
  3653. if { ac_try='./conftest$ac_cv_exeext'
  3654. { { case "(($ac_try" in
  3655. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3656. *) ac_try_echo=$ac_try;;
  3657. esac
  3658. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3659. $as_echo "$ac_try_echo"; } >&5
  3660. (eval "$ac_try") 2>&5
  3661. ac_status=$?
  3662. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3663. test $ac_status = 0; }; }; then
  3664. cross_compiling=no
  3665. else
  3666. if test "$cross_compiling" = maybe; then
  3667. cross_compiling=yes
  3668. else
  3669. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3670. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3671. as_fn_error $? "cannot run C compiled programs.
  3672. If you meant to cross compile, use \`--host'.
  3673. See \`config.log' for more details" "$LINENO" 5; }
  3674. fi
  3675. fi
  3676. fi
  3677. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
  3678. $as_echo "$cross_compiling" >&6; }
  3679. rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
  3680. ac_clean_files=$ac_clean_files_save
  3681. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
  3682. $as_echo_n "checking for suffix of object files... " >&6; }
  3683. if ${ac_cv_objext+:} false; then :
  3684. $as_echo_n "(cached) " >&6
  3685. else
  3686. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3687. /* end confdefs.h. */
  3688. int
  3689. main ()
  3690. {
  3691. ;
  3692. return 0;
  3693. }
  3694. _ACEOF
  3695. rm -f conftest.o conftest.obj
  3696. if { { ac_try="$ac_compile"
  3697. case "(($ac_try" in
  3698. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  3699. *) ac_try_echo=$ac_try;;
  3700. esac
  3701. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  3702. $as_echo "$ac_try_echo"; } >&5
  3703. (eval "$ac_compile") 2>&5
  3704. ac_status=$?
  3705. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  3706. test $ac_status = 0; }; then :
  3707. for ac_file in conftest.o conftest.obj conftest.*; do
  3708. test -f "$ac_file" || continue;
  3709. case $ac_file in
  3710. *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
  3711. *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
  3712. break;;
  3713. esac
  3714. done
  3715. else
  3716. $as_echo "$as_me: failed program was:" >&5
  3717. sed 's/^/| /' conftest.$ac_ext >&5
  3718. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  3719. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  3720. as_fn_error $? "cannot compute suffix of object files: cannot compile
  3721. See \`config.log' for more details" "$LINENO" 5; }
  3722. fi
  3723. rm -f conftest.$ac_cv_objext conftest.$ac_ext
  3724. fi
  3725. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
  3726. $as_echo "$ac_cv_objext" >&6; }
  3727. OBJEXT=$ac_cv_objext
  3728. ac_objext=$OBJEXT
  3729. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
  3730. $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
  3731. if ${ac_cv_c_compiler_gnu+:} false; then :
  3732. $as_echo_n "(cached) " >&6
  3733. else
  3734. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3735. /* end confdefs.h. */
  3736. int
  3737. main ()
  3738. {
  3739. #ifndef __GNUC__
  3740. choke me
  3741. #endif
  3742. ;
  3743. return 0;
  3744. }
  3745. _ACEOF
  3746. if ac_fn_c_try_compile "$LINENO"; then :
  3747. ac_compiler_gnu=yes
  3748. else
  3749. ac_compiler_gnu=no
  3750. fi
  3751. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3752. ac_cv_c_compiler_gnu=$ac_compiler_gnu
  3753. fi
  3754. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
  3755. $as_echo "$ac_cv_c_compiler_gnu" >&6; }
  3756. if test $ac_compiler_gnu = yes; then
  3757. GCC=yes
  3758. else
  3759. GCC=
  3760. fi
  3761. ac_test_CFLAGS=${CFLAGS+set}
  3762. ac_save_CFLAGS=$CFLAGS
  3763. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
  3764. $as_echo_n "checking whether $CC accepts -g... " >&6; }
  3765. if ${ac_cv_prog_cc_g+:} false; then :
  3766. $as_echo_n "(cached) " >&6
  3767. else
  3768. ac_save_c_werror_flag=$ac_c_werror_flag
  3769. ac_c_werror_flag=yes
  3770. ac_cv_prog_cc_g=no
  3771. CFLAGS="-g"
  3772. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3773. /* end confdefs.h. */
  3774. int
  3775. main ()
  3776. {
  3777. ;
  3778. return 0;
  3779. }
  3780. _ACEOF
  3781. if ac_fn_c_try_compile "$LINENO"; then :
  3782. ac_cv_prog_cc_g=yes
  3783. else
  3784. CFLAGS=""
  3785. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3786. /* end confdefs.h. */
  3787. int
  3788. main ()
  3789. {
  3790. ;
  3791. return 0;
  3792. }
  3793. _ACEOF
  3794. if ac_fn_c_try_compile "$LINENO"; then :
  3795. else
  3796. ac_c_werror_flag=$ac_save_c_werror_flag
  3797. CFLAGS="-g"
  3798. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3799. /* end confdefs.h. */
  3800. int
  3801. main ()
  3802. {
  3803. ;
  3804. return 0;
  3805. }
  3806. _ACEOF
  3807. if ac_fn_c_try_compile "$LINENO"; then :
  3808. ac_cv_prog_cc_g=yes
  3809. fi
  3810. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3811. fi
  3812. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3813. fi
  3814. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  3815. ac_c_werror_flag=$ac_save_c_werror_flag
  3816. fi
  3817. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
  3818. $as_echo "$ac_cv_prog_cc_g" >&6; }
  3819. if test "$ac_test_CFLAGS" = set; then
  3820. CFLAGS=$ac_save_CFLAGS
  3821. elif test $ac_cv_prog_cc_g = yes; then
  3822. if test "$GCC" = yes; then
  3823. CFLAGS="-g -O2"
  3824. else
  3825. CFLAGS="-g"
  3826. fi
  3827. else
  3828. if test "$GCC" = yes; then
  3829. CFLAGS="-O2"
  3830. else
  3831. CFLAGS=
  3832. fi
  3833. fi
  3834. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
  3835. $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
  3836. if ${ac_cv_prog_cc_c89+:} false; then :
  3837. $as_echo_n "(cached) " >&6
  3838. else
  3839. ac_cv_prog_cc_c89=no
  3840. ac_save_CC=$CC
  3841. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3842. /* end confdefs.h. */
  3843. #include <stdarg.h>
  3844. #include <stdio.h>
  3845. struct stat;
  3846. /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
  3847. struct buf { int x; };
  3848. FILE * (*rcsopen) (struct buf *, struct stat *, int);
  3849. static char *e (p, i)
  3850. char **p;
  3851. int i;
  3852. {
  3853. return p[i];
  3854. }
  3855. static char *f (char * (*g) (char **, int), char **p, ...)
  3856. {
  3857. char *s;
  3858. va_list v;
  3859. va_start (v,p);
  3860. s = g (p, va_arg (v,int));
  3861. va_end (v);
  3862. return s;
  3863. }
  3864. /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
  3865. function prototypes and stuff, but not '\xHH' hex character constants.
  3866. These don't provoke an error unfortunately, instead are silently treated
  3867. as 'x'. The following induces an error, until -std is added to get
  3868. proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
  3869. array size at least. It's necessary to write '\x00'==0 to get something
  3870. that's true only with -std. */
  3871. int osf4_cc_array ['\x00' == 0 ? 1 : -1];
  3872. /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
  3873. inside strings and character constants. */
  3874. #define FOO(x) 'x'
  3875. int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
  3876. int test (int i, double x);
  3877. struct s1 {int (*f) (int a);};
  3878. struct s2 {int (*f) (double a);};
  3879. int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
  3880. int argc;
  3881. char **argv;
  3882. int
  3883. main ()
  3884. {
  3885. return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
  3886. ;
  3887. return 0;
  3888. }
  3889. _ACEOF
  3890. for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
  3891. -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
  3892. do
  3893. CC="$ac_save_CC $ac_arg"
  3894. if ac_fn_c_try_compile "$LINENO"; then :
  3895. ac_cv_prog_cc_c89=$ac_arg
  3896. fi
  3897. rm -f core conftest.err conftest.$ac_objext
  3898. test "x$ac_cv_prog_cc_c89" != "xno" && break
  3899. done
  3900. rm -f conftest.$ac_ext
  3901. CC=$ac_save_CC
  3902. fi
  3903. # AC_CACHE_VAL
  3904. case "x$ac_cv_prog_cc_c89" in
  3905. x)
  3906. { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
  3907. $as_echo "none needed" >&6; } ;;
  3908. xno)
  3909. { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
  3910. $as_echo "unsupported" >&6; } ;;
  3911. *)
  3912. CC="$CC $ac_cv_prog_cc_c89"
  3913. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
  3914. $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
  3915. esac
  3916. if test "x$ac_cv_prog_cc_c89" != xno; then :
  3917. fi
  3918. ac_ext=c
  3919. ac_cpp='$CPP $CPPFLAGS'
  3920. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3921. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3922. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3923. ac_ext=c
  3924. ac_cpp='$CPP $CPPFLAGS'
  3925. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  3926. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  3927. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  3928. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
  3929. $as_echo_n "checking how to run the C preprocessor... " >&6; }
  3930. # On Suns, sometimes $CPP names a directory.
  3931. if test -n "$CPP" && test -d "$CPP"; then
  3932. CPP=
  3933. fi
  3934. if test -z "$CPP"; then
  3935. if ${ac_cv_prog_CPP+:} false; then :
  3936. $as_echo_n "(cached) " >&6
  3937. else
  3938. # Double quotes because CPP needs to be expanded
  3939. for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
  3940. do
  3941. ac_preproc_ok=false
  3942. for ac_c_preproc_warn_flag in '' yes
  3943. do
  3944. # Use a header file that comes with gcc, so configuring glibc
  3945. # with a fresh cross-compiler works.
  3946. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  3947. # <limits.h> exists even on freestanding compilers.
  3948. # On the NeXT, cc -E runs the code through the compiler's parser,
  3949. # not just through cpp. "Syntax error" is here to catch this case.
  3950. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3951. /* end confdefs.h. */
  3952. #ifdef __STDC__
  3953. # include <limits.h>
  3954. #else
  3955. # include <assert.h>
  3956. #endif
  3957. Syntax error
  3958. _ACEOF
  3959. if ac_fn_c_try_cpp "$LINENO"; then :
  3960. else
  3961. # Broken: fails on valid input.
  3962. continue
  3963. fi
  3964. rm -f conftest.err conftest.i conftest.$ac_ext
  3965. # OK, works on sane cases. Now check whether nonexistent headers
  3966. # can be detected and how.
  3967. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  3968. /* end confdefs.h. */
  3969. #include <ac_nonexistent.h>
  3970. _ACEOF
  3971. if ac_fn_c_try_cpp "$LINENO"; then :
  3972. # Broken: success on invalid input.
  3973. continue
  3974. else
  3975. # Passes both tests.
  3976. ac_preproc_ok=:
  3977. break
  3978. fi
  3979. rm -f conftest.err conftest.i conftest.$ac_ext
  3980. done
  3981. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  3982. rm -f conftest.i conftest.err conftest.$ac_ext
  3983. if $ac_preproc_ok; then :
  3984. break
  3985. fi
  3986. done
  3987. ac_cv_prog_CPP=$CPP
  3988. fi
  3989. CPP=$ac_cv_prog_CPP
  3990. else
  3991. ac_cv_prog_CPP=$CPP
  3992. fi
  3993. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
  3994. $as_echo "$CPP" >&6; }
  3995. ac_preproc_ok=false
  3996. for ac_c_preproc_warn_flag in '' yes
  3997. do
  3998. # Use a header file that comes with gcc, so configuring glibc
  3999. # with a fresh cross-compiler works.
  4000. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  4001. # <limits.h> exists even on freestanding compilers.
  4002. # On the NeXT, cc -E runs the code through the compiler's parser,
  4003. # not just through cpp. "Syntax error" is here to catch this case.
  4004. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4005. /* end confdefs.h. */
  4006. #ifdef __STDC__
  4007. # include <limits.h>
  4008. #else
  4009. # include <assert.h>
  4010. #endif
  4011. Syntax error
  4012. _ACEOF
  4013. if ac_fn_c_try_cpp "$LINENO"; then :
  4014. else
  4015. # Broken: fails on valid input.
  4016. continue
  4017. fi
  4018. rm -f conftest.err conftest.i conftest.$ac_ext
  4019. # OK, works on sane cases. Now check whether nonexistent headers
  4020. # can be detected and how.
  4021. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4022. /* end confdefs.h. */
  4023. #include <ac_nonexistent.h>
  4024. _ACEOF
  4025. if ac_fn_c_try_cpp "$LINENO"; then :
  4026. # Broken: success on invalid input.
  4027. continue
  4028. else
  4029. # Passes both tests.
  4030. ac_preproc_ok=:
  4031. break
  4032. fi
  4033. rm -f conftest.err conftest.i conftest.$ac_ext
  4034. done
  4035. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  4036. rm -f conftest.i conftest.err conftest.$ac_ext
  4037. if $ac_preproc_ok; then :
  4038. else
  4039. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  4040. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  4041. as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
  4042. See \`config.log' for more details" "$LINENO" 5; }
  4043. fi
  4044. ac_ext=c
  4045. ac_cpp='$CPP $CPPFLAGS'
  4046. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  4047. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  4048. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  4049. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
  4050. $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
  4051. if ${ac_cv_path_GREP+:} false; then :
  4052. $as_echo_n "(cached) " >&6
  4053. else
  4054. if test -z "$GREP"; then
  4055. ac_path_GREP_found=false
  4056. # Loop through the user's path and test for each of PROGNAME-LIST
  4057. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4058. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  4059. do
  4060. IFS=$as_save_IFS
  4061. test -z "$as_dir" && as_dir=.
  4062. for ac_prog in grep ggrep; do
  4063. for ac_exec_ext in '' $ac_executable_extensions; do
  4064. ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
  4065. as_fn_executable_p "$ac_path_GREP" || continue
  4066. # Check for GNU ac_path_GREP and select it if it is found.
  4067. # Check for GNU $ac_path_GREP
  4068. case `"$ac_path_GREP" --version 2>&1` in
  4069. *GNU*)
  4070. ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
  4071. *)
  4072. ac_count=0
  4073. $as_echo_n 0123456789 >"conftest.in"
  4074. while :
  4075. do
  4076. cat "conftest.in" "conftest.in" >"conftest.tmp"
  4077. mv "conftest.tmp" "conftest.in"
  4078. cp "conftest.in" "conftest.nl"
  4079. $as_echo 'GREP' >> "conftest.nl"
  4080. "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  4081. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  4082. as_fn_arith $ac_count + 1 && ac_count=$as_val
  4083. if test $ac_count -gt ${ac_path_GREP_max-0}; then
  4084. # Best one so far, save it but keep looking for a better one
  4085. ac_cv_path_GREP="$ac_path_GREP"
  4086. ac_path_GREP_max=$ac_count
  4087. fi
  4088. # 10*(2^10) chars as input seems more than enough
  4089. test $ac_count -gt 10 && break
  4090. done
  4091. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  4092. esac
  4093. $ac_path_GREP_found && break 3
  4094. done
  4095. done
  4096. done
  4097. IFS=$as_save_IFS
  4098. if test -z "$ac_cv_path_GREP"; then
  4099. as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  4100. fi
  4101. else
  4102. ac_cv_path_GREP=$GREP
  4103. fi
  4104. fi
  4105. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
  4106. $as_echo "$ac_cv_path_GREP" >&6; }
  4107. GREP="$ac_cv_path_GREP"
  4108. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  4109. $as_echo_n "checking for egrep... " >&6; }
  4110. if ${ac_cv_path_EGREP+:} false; then :
  4111. $as_echo_n "(cached) " >&6
  4112. else
  4113. if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
  4114. then ac_cv_path_EGREP="$GREP -E"
  4115. else
  4116. if test -z "$EGREP"; then
  4117. ac_path_EGREP_found=false
  4118. # Loop through the user's path and test for each of PROGNAME-LIST
  4119. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4120. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  4121. do
  4122. IFS=$as_save_IFS
  4123. test -z "$as_dir" && as_dir=.
  4124. for ac_prog in egrep; do
  4125. for ac_exec_ext in '' $ac_executable_extensions; do
  4126. ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
  4127. as_fn_executable_p "$ac_path_EGREP" || continue
  4128. # Check for GNU ac_path_EGREP and select it if it is found.
  4129. # Check for GNU $ac_path_EGREP
  4130. case `"$ac_path_EGREP" --version 2>&1` in
  4131. *GNU*)
  4132. ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
  4133. *)
  4134. ac_count=0
  4135. $as_echo_n 0123456789 >"conftest.in"
  4136. while :
  4137. do
  4138. cat "conftest.in" "conftest.in" >"conftest.tmp"
  4139. mv "conftest.tmp" "conftest.in"
  4140. cp "conftest.in" "conftest.nl"
  4141. $as_echo 'EGREP' >> "conftest.nl"
  4142. "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  4143. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  4144. as_fn_arith $ac_count + 1 && ac_count=$as_val
  4145. if test $ac_count -gt ${ac_path_EGREP_max-0}; then
  4146. # Best one so far, save it but keep looking for a better one
  4147. ac_cv_path_EGREP="$ac_path_EGREP"
  4148. ac_path_EGREP_max=$ac_count
  4149. fi
  4150. # 10*(2^10) chars as input seems more than enough
  4151. test $ac_count -gt 10 && break
  4152. done
  4153. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  4154. esac
  4155. $ac_path_EGREP_found && break 3
  4156. done
  4157. done
  4158. done
  4159. IFS=$as_save_IFS
  4160. if test -z "$ac_cv_path_EGREP"; then
  4161. as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  4162. fi
  4163. else
  4164. ac_cv_path_EGREP=$EGREP
  4165. fi
  4166. fi
  4167. fi
  4168. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
  4169. $as_echo "$ac_cv_path_EGREP" >&6; }
  4170. EGREP="$ac_cv_path_EGREP"
  4171. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
  4172. $as_echo_n "checking for ANSI C header files... " >&6; }
  4173. if ${ac_cv_header_stdc+:} false; then :
  4174. $as_echo_n "(cached) " >&6
  4175. else
  4176. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4177. /* end confdefs.h. */
  4178. #include <stdlib.h>
  4179. #include <stdarg.h>
  4180. #include <string.h>
  4181. #include <float.h>
  4182. int
  4183. main ()
  4184. {
  4185. ;
  4186. return 0;
  4187. }
  4188. _ACEOF
  4189. if ac_fn_c_try_compile "$LINENO"; then :
  4190. ac_cv_header_stdc=yes
  4191. else
  4192. ac_cv_header_stdc=no
  4193. fi
  4194. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4195. if test $ac_cv_header_stdc = yes; then
  4196. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  4197. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4198. /* end confdefs.h. */
  4199. #include <string.h>
  4200. _ACEOF
  4201. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  4202. $EGREP "memchr" >/dev/null 2>&1; then :
  4203. else
  4204. ac_cv_header_stdc=no
  4205. fi
  4206. rm -f conftest*
  4207. fi
  4208. if test $ac_cv_header_stdc = yes; then
  4209. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  4210. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4211. /* end confdefs.h. */
  4212. #include <stdlib.h>
  4213. _ACEOF
  4214. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  4215. $EGREP "free" >/dev/null 2>&1; then :
  4216. else
  4217. ac_cv_header_stdc=no
  4218. fi
  4219. rm -f conftest*
  4220. fi
  4221. if test $ac_cv_header_stdc = yes; then
  4222. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  4223. if test "$cross_compiling" = yes; then :
  4224. :
  4225. else
  4226. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4227. /* end confdefs.h. */
  4228. #include <ctype.h>
  4229. #include <stdlib.h>
  4230. #if ((' ' & 0x0FF) == 0x020)
  4231. # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  4232. # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  4233. #else
  4234. # define ISLOWER(c) \
  4235. (('a' <= (c) && (c) <= 'i') \
  4236. || ('j' <= (c) && (c) <= 'r') \
  4237. || ('s' <= (c) && (c) <= 'z'))
  4238. # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
  4239. #endif
  4240. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  4241. int
  4242. main ()
  4243. {
  4244. int i;
  4245. for (i = 0; i < 256; i++)
  4246. if (XOR (islower (i), ISLOWER (i))
  4247. || toupper (i) != TOUPPER (i))
  4248. return 2;
  4249. return 0;
  4250. }
  4251. _ACEOF
  4252. if ac_fn_c_try_run "$LINENO"; then :
  4253. else
  4254. ac_cv_header_stdc=no
  4255. fi
  4256. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  4257. conftest.$ac_objext conftest.beam conftest.$ac_ext
  4258. fi
  4259. fi
  4260. fi
  4261. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
  4262. $as_echo "$ac_cv_header_stdc" >&6; }
  4263. if test $ac_cv_header_stdc = yes; then
  4264. $as_echo "#define STDC_HEADERS 1" >>confdefs.h
  4265. fi
  4266. # On IRIX 5.3, sys/types and inttypes.h are conflicting.
  4267. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
  4268. inttypes.h stdint.h unistd.h
  4269. do :
  4270. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  4271. ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
  4272. "
  4273. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  4274. cat >>confdefs.h <<_ACEOF
  4275. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  4276. _ACEOF
  4277. fi
  4278. done
  4279. ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
  4280. if test "x$ac_cv_header_minix_config_h" = xyes; then :
  4281. MINIX=yes
  4282. else
  4283. MINIX=
  4284. fi
  4285. if test "$MINIX" = yes; then
  4286. $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
  4287. $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
  4288. $as_echo "#define _MINIX 1" >>confdefs.h
  4289. fi
  4290. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
  4291. $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
  4292. if ${ac_cv_safe_to_define___extensions__+:} false; then :
  4293. $as_echo_n "(cached) " >&6
  4294. else
  4295. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4296. /* end confdefs.h. */
  4297. # define __EXTENSIONS__ 1
  4298. $ac_includes_default
  4299. int
  4300. main ()
  4301. {
  4302. ;
  4303. return 0;
  4304. }
  4305. _ACEOF
  4306. if ac_fn_c_try_compile "$LINENO"; then :
  4307. ac_cv_safe_to_define___extensions__=yes
  4308. else
  4309. ac_cv_safe_to_define___extensions__=no
  4310. fi
  4311. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4312. fi
  4313. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
  4314. $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
  4315. test $ac_cv_safe_to_define___extensions__ = yes &&
  4316. $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
  4317. $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
  4318. $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
  4319. $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
  4320. $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
  4321. # System default paths
  4322. astsbindir='${sbindir}'
  4323. astetcdir='${sysconfdir}/asterisk'
  4324. astheaderdir='${includedir}/asterisk'
  4325. astlibdir='${libdir}'
  4326. astmoddir='${libdir}/asterisk/modules'
  4327. astmandir='${mandir}'
  4328. astvarlibdir='${localstatedir}/lib/asterisk'
  4329. astdatadir='${astvarlibdir}'
  4330. astdbdir='${astvarlibdir}'
  4331. astkeydir='${astvarlibdir}'
  4332. astspooldir='${localstatedir}/spool/asterisk'
  4333. astlogdir='${localstatedir}/log/asterisk'
  4334. astvarrundir='${localstatedir}/run/asterisk'
  4335. case "${host_os}" in
  4336. *bsd*)
  4337. if test ${prefix} = 'NONE'; then
  4338. astvarlibdir='${prefix}/share/asterisk'
  4339. astdbdir='${localstatedir}/db/asterisk'
  4340. fi
  4341. ;;
  4342. darwin*)
  4343. if test ${prefix} = 'NONE'; then
  4344. astvarrundir='/Library/Application Support/Asterisk/Run'
  4345. fi
  4346. ;;
  4347. esac
  4348. case "${host_os}" in
  4349. freebsd*)
  4350. ac_default_prefix=/usr/local
  4351. CPPFLAGS=-I/usr/local/include
  4352. LDFLAGS=-L/usr/local/lib
  4353. ;;
  4354. openbsd*)
  4355. ac_default_prefix=/usr/local
  4356. if test ${prefix} = '/usr/local' || test ${prefix} = 'NONE'; then
  4357. if test ${sysconfdir} = '${prefix}/etc'; then
  4358. astetcdir=/etc/asterisk
  4359. fi
  4360. if test ${mandir} = '${prefix}/man'; then
  4361. astmandir=/usr/share/man
  4362. fi
  4363. fi
  4364. CPPFLAGS=-I/usr/local/include
  4365. LDFLAGS=-L/usr/local/lib
  4366. ;;
  4367. darwin*)
  4368. ac_default_prefix=/usr/local
  4369. if test ${prefix} = 'NONE'; then
  4370. astmoddir='/Library/Application Support/Asterisk/Modules'
  4371. astvarlibdir='/Library/Application Support/Asterisk'
  4372. astlogdir=/Library/Logs/Asterisk
  4373. astvarrundir='/Library/Application Support/Asterisk/Run'
  4374. fi
  4375. $as_echo "#define AST_POLL_COMPAT 1" >>confdefs.h
  4376. $as_echo "#define _DARWIN_UNLIMITED_SELECT 1" >>confdefs.h
  4377. ;;
  4378. solaris*)
  4379. if test ${prefix} = 'NONE'; then
  4380. astetcdir=/var/etc/asterisk
  4381. astsbindir=/opt/asterisk/sbin
  4382. astlibdir=/opt/asterisk/lib
  4383. astmoddir=/opt/asterisk/lib/modules
  4384. astheaderdir=/opt/asterisk/include
  4385. astmandir=/opt/asterisk/man
  4386. astvarlibdir=/var/opt/asterisk
  4387. astspooldir=/var/spool/asterisk
  4388. astlogdir=/var/log/asterisk
  4389. astvarrundir=/var/run/asterisk
  4390. fi
  4391. ;;
  4392. *)
  4393. ac_default_prefix=/usr
  4394. if test ${prefix} = '/usr' || test ${prefix} = 'NONE'; then
  4395. if test ${sysconfdir} = '${prefix}/etc'; then
  4396. sysconfdir=/etc
  4397. fi
  4398. if test ${mandir} = '${prefix}/man'; then
  4399. mandir=/usr/share/man
  4400. fi
  4401. fi
  4402. ;;
  4403. esac
  4404. if test ${prefix} = ${ac_default_prefix} || test ${prefix} = 'NONE'; then
  4405. if test ${localstatedir} = '${prefix}/var'; then
  4406. localstatedir=/var
  4407. fi
  4408. fi
  4409. BUILD_PLATFORM=${build}
  4410. BUILD_CPU=${build_cpu}
  4411. BUILD_VENDOR=${build_vendor}
  4412. BUILD_OS=${build_os}
  4413. HOST_PLATFORM=${host}
  4414. HOST_CPU=${host_cpu}
  4415. HOST_VENDOR=${host_vendor}
  4416. HOST_OS=${host_os}
  4417. PBX_WINARCH=0
  4418. case "${host_os}" in
  4419. freebsd*)
  4420. OSARCH=FreeBSD
  4421. ;;
  4422. netbsd*)
  4423. OSARCH=NetBSD
  4424. ;;
  4425. openbsd*)
  4426. OSARCH=OpenBSD
  4427. ;;
  4428. solaris*)
  4429. OSARCH=SunOS
  4430. ;;
  4431. mingw32)
  4432. OSARCH=mingw32
  4433. PBX_WINARCH=1
  4434. ;;
  4435. cygwin)
  4436. OSARCH=cygwin
  4437. PBX_WINARCH=1
  4438. ;;
  4439. linux-gnueabi* | linux-gnuspe)
  4440. OSARCH=linux-gnu
  4441. ;;
  4442. kfreebsd*-gnu)
  4443. OSARCH=kfreebsd-gnu
  4444. ;;
  4445. *)
  4446. OSARCH=${host_os}
  4447. ;;
  4448. esac
  4449. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
  4450. $as_echo_n "checking whether char is unsigned... " >&6; }
  4451. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  4452. /* end confdefs.h. */
  4453. #include <limits.h>
  4454. #if CHAR_MIN == 0
  4455. #error
  4456. #endif
  4457. _ACEOF
  4458. if ac_fn_c_try_compile "$LINENO"; then :
  4459. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4460. $as_echo "no" >&6; }
  4461. CONFIG_SIGNED_CHAR=""
  4462. else
  4463. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  4464. $as_echo "yes" >&6; }
  4465. CONFIG_SIGNED_CHAR="-fsigned-char"
  4466. fi
  4467. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  4468. # check for uname
  4469. if test -n "$ac_tool_prefix"; then
  4470. # Extract the first word of "${ac_tool_prefix}uname", so it can be a program name with args.
  4471. set dummy ${ac_tool_prefix}uname; ac_word=$2
  4472. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4473. $as_echo_n "checking for $ac_word... " >&6; }
  4474. if ${ac_cv_path_UNAME+:} false; then :
  4475. $as_echo_n "(cached) " >&6
  4476. else
  4477. case $UNAME in
  4478. [\\/]* | ?:[\\/]*)
  4479. ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path.
  4480. ;;
  4481. *)
  4482. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4483. for as_dir in $PATH
  4484. do
  4485. IFS=$as_save_IFS
  4486. test -z "$as_dir" && as_dir=.
  4487. for ac_exec_ext in '' $ac_executable_extensions; do
  4488. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4489. ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext"
  4490. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4491. break 2
  4492. fi
  4493. done
  4494. done
  4495. IFS=$as_save_IFS
  4496. ;;
  4497. esac
  4498. fi
  4499. UNAME=$ac_cv_path_UNAME
  4500. if test -n "$UNAME"; then
  4501. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5
  4502. $as_echo "$UNAME" >&6; }
  4503. else
  4504. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4505. $as_echo "no" >&6; }
  4506. fi
  4507. fi
  4508. if test -z "$ac_cv_path_UNAME"; then
  4509. ac_pt_UNAME=$UNAME
  4510. # Extract the first word of "uname", so it can be a program name with args.
  4511. set dummy uname; ac_word=$2
  4512. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4513. $as_echo_n "checking for $ac_word... " >&6; }
  4514. if ${ac_cv_path_ac_pt_UNAME+:} false; then :
  4515. $as_echo_n "(cached) " >&6
  4516. else
  4517. case $ac_pt_UNAME in
  4518. [\\/]* | ?:[\\/]*)
  4519. ac_cv_path_ac_pt_UNAME="$ac_pt_UNAME" # Let the user override the test with a path.
  4520. ;;
  4521. *)
  4522. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4523. for as_dir in $PATH
  4524. do
  4525. IFS=$as_save_IFS
  4526. test -z "$as_dir" && as_dir=.
  4527. for ac_exec_ext in '' $ac_executable_extensions; do
  4528. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4529. ac_cv_path_ac_pt_UNAME="$as_dir/$ac_word$ac_exec_ext"
  4530. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4531. break 2
  4532. fi
  4533. done
  4534. done
  4535. IFS=$as_save_IFS
  4536. ;;
  4537. esac
  4538. fi
  4539. ac_pt_UNAME=$ac_cv_path_ac_pt_UNAME
  4540. if test -n "$ac_pt_UNAME"; then
  4541. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_UNAME" >&5
  4542. $as_echo "$ac_pt_UNAME" >&6; }
  4543. else
  4544. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4545. $as_echo "no" >&6; }
  4546. fi
  4547. if test "x$ac_pt_UNAME" = x; then
  4548. UNAME="No"
  4549. else
  4550. case $cross_compiling:$ac_tool_warned in
  4551. yes:)
  4552. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4553. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4554. ac_tool_warned=yes ;;
  4555. esac
  4556. UNAME=$ac_pt_UNAME
  4557. fi
  4558. else
  4559. UNAME="$ac_cv_path_UNAME"
  4560. fi
  4561. if test ! x"${UNAME}" = xNo; then
  4562. PBX_OSREV=$(${UNAME} -r)
  4563. fi
  4564. # cross-compile checks
  4565. if test "${cross_compiling}" = "yes";
  4566. then
  4567. if test -n "$ac_tool_prefix"; then
  4568. # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
  4569. set dummy ${ac_tool_prefix}gcc; ac_word=$2
  4570. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4571. $as_echo_n "checking for $ac_word... " >&6; }
  4572. if ${ac_cv_prog_CC+:} false; then :
  4573. $as_echo_n "(cached) " >&6
  4574. else
  4575. if test -n "$CC"; then
  4576. ac_cv_prog_CC="$CC" # Let the user override the test.
  4577. else
  4578. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4579. for as_dir in $PATH
  4580. do
  4581. IFS=$as_save_IFS
  4582. test -z "$as_dir" && as_dir=.
  4583. for ac_exec_ext in '' $ac_executable_extensions; do
  4584. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4585. ac_cv_prog_CC="${ac_tool_prefix}gcc"
  4586. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4587. break 2
  4588. fi
  4589. done
  4590. done
  4591. IFS=$as_save_IFS
  4592. fi
  4593. fi
  4594. CC=$ac_cv_prog_CC
  4595. if test -n "$CC"; then
  4596. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
  4597. $as_echo "$CC" >&6; }
  4598. else
  4599. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4600. $as_echo "no" >&6; }
  4601. fi
  4602. fi
  4603. if test -z "$ac_cv_prog_CC"; then
  4604. ac_ct_CC=$CC
  4605. # Extract the first word of "gcc", so it can be a program name with args.
  4606. set dummy gcc; ac_word=$2
  4607. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4608. $as_echo_n "checking for $ac_word... " >&6; }
  4609. if ${ac_cv_prog_ac_ct_CC+:} false; then :
  4610. $as_echo_n "(cached) " >&6
  4611. else
  4612. if test -n "$ac_ct_CC"; then
  4613. ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
  4614. else
  4615. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4616. for as_dir in $PATH
  4617. do
  4618. IFS=$as_save_IFS
  4619. test -z "$as_dir" && as_dir=.
  4620. for ac_exec_ext in '' $ac_executable_extensions; do
  4621. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4622. ac_cv_prog_ac_ct_CC="gcc"
  4623. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4624. break 2
  4625. fi
  4626. done
  4627. done
  4628. IFS=$as_save_IFS
  4629. fi
  4630. fi
  4631. ac_ct_CC=$ac_cv_prog_ac_ct_CC
  4632. if test -n "$ac_ct_CC"; then
  4633. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
  4634. $as_echo "$ac_ct_CC" >&6; }
  4635. else
  4636. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4637. $as_echo "no" >&6; }
  4638. fi
  4639. if test "x$ac_ct_CC" = x; then
  4640. CC=":"
  4641. else
  4642. case $cross_compiling:$ac_tool_warned in
  4643. yes:)
  4644. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4645. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4646. ac_tool_warned=yes ;;
  4647. esac
  4648. CC=$ac_ct_CC
  4649. fi
  4650. else
  4651. CC="$ac_cv_prog_CC"
  4652. fi
  4653. if test -n "$ac_tool_prefix"; then
  4654. # Extract the first word of "${ac_tool_prefix}g++", so it can be a program name with args.
  4655. set dummy ${ac_tool_prefix}g++; ac_word=$2
  4656. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4657. $as_echo_n "checking for $ac_word... " >&6; }
  4658. if ${ac_cv_prog_CXX+:} false; then :
  4659. $as_echo_n "(cached) " >&6
  4660. else
  4661. if test -n "$CXX"; then
  4662. ac_cv_prog_CXX="$CXX" # Let the user override the test.
  4663. else
  4664. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4665. for as_dir in $PATH
  4666. do
  4667. IFS=$as_save_IFS
  4668. test -z "$as_dir" && as_dir=.
  4669. for ac_exec_ext in '' $ac_executable_extensions; do
  4670. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4671. ac_cv_prog_CXX="${ac_tool_prefix}g++"
  4672. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4673. break 2
  4674. fi
  4675. done
  4676. done
  4677. IFS=$as_save_IFS
  4678. fi
  4679. fi
  4680. CXX=$ac_cv_prog_CXX
  4681. if test -n "$CXX"; then
  4682. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
  4683. $as_echo "$CXX" >&6; }
  4684. else
  4685. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4686. $as_echo "no" >&6; }
  4687. fi
  4688. fi
  4689. if test -z "$ac_cv_prog_CXX"; then
  4690. ac_ct_CXX=$CXX
  4691. # Extract the first word of "g++", so it can be a program name with args.
  4692. set dummy g++; ac_word=$2
  4693. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4694. $as_echo_n "checking for $ac_word... " >&6; }
  4695. if ${ac_cv_prog_ac_ct_CXX+:} false; then :
  4696. $as_echo_n "(cached) " >&6
  4697. else
  4698. if test -n "$ac_ct_CXX"; then
  4699. ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
  4700. else
  4701. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4702. for as_dir in $PATH
  4703. do
  4704. IFS=$as_save_IFS
  4705. test -z "$as_dir" && as_dir=.
  4706. for ac_exec_ext in '' $ac_executable_extensions; do
  4707. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4708. ac_cv_prog_ac_ct_CXX="g++"
  4709. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4710. break 2
  4711. fi
  4712. done
  4713. done
  4714. IFS=$as_save_IFS
  4715. fi
  4716. fi
  4717. ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
  4718. if test -n "$ac_ct_CXX"; then
  4719. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
  4720. $as_echo "$ac_ct_CXX" >&6; }
  4721. else
  4722. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4723. $as_echo "no" >&6; }
  4724. fi
  4725. if test "x$ac_ct_CXX" = x; then
  4726. CXX=":"
  4727. else
  4728. case $cross_compiling:$ac_tool_warned in
  4729. yes:)
  4730. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4731. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4732. ac_tool_warned=yes ;;
  4733. esac
  4734. CXX=$ac_ct_CXX
  4735. fi
  4736. else
  4737. CXX="$ac_cv_prog_CXX"
  4738. fi
  4739. if test -n "$ac_tool_prefix"; then
  4740. # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
  4741. set dummy ${ac_tool_prefix}ld; ac_word=$2
  4742. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4743. $as_echo_n "checking for $ac_word... " >&6; }
  4744. if ${ac_cv_prog_LD+:} false; then :
  4745. $as_echo_n "(cached) " >&6
  4746. else
  4747. if test -n "$LD"; then
  4748. ac_cv_prog_LD="$LD" # Let the user override the test.
  4749. else
  4750. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4751. for as_dir in $PATH
  4752. do
  4753. IFS=$as_save_IFS
  4754. test -z "$as_dir" && as_dir=.
  4755. for ac_exec_ext in '' $ac_executable_extensions; do
  4756. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4757. ac_cv_prog_LD="${ac_tool_prefix}ld"
  4758. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4759. break 2
  4760. fi
  4761. done
  4762. done
  4763. IFS=$as_save_IFS
  4764. fi
  4765. fi
  4766. LD=$ac_cv_prog_LD
  4767. if test -n "$LD"; then
  4768. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
  4769. $as_echo "$LD" >&6; }
  4770. else
  4771. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4772. $as_echo "no" >&6; }
  4773. fi
  4774. fi
  4775. if test -z "$ac_cv_prog_LD"; then
  4776. ac_ct_LD=$LD
  4777. # Extract the first word of "ld", so it can be a program name with args.
  4778. set dummy ld; ac_word=$2
  4779. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4780. $as_echo_n "checking for $ac_word... " >&6; }
  4781. if ${ac_cv_prog_ac_ct_LD+:} false; then :
  4782. $as_echo_n "(cached) " >&6
  4783. else
  4784. if test -n "$ac_ct_LD"; then
  4785. ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
  4786. else
  4787. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4788. for as_dir in $PATH
  4789. do
  4790. IFS=$as_save_IFS
  4791. test -z "$as_dir" && as_dir=.
  4792. for ac_exec_ext in '' $ac_executable_extensions; do
  4793. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4794. ac_cv_prog_ac_ct_LD="ld"
  4795. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4796. break 2
  4797. fi
  4798. done
  4799. done
  4800. IFS=$as_save_IFS
  4801. fi
  4802. fi
  4803. ac_ct_LD=$ac_cv_prog_ac_ct_LD
  4804. if test -n "$ac_ct_LD"; then
  4805. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LD" >&5
  4806. $as_echo "$ac_ct_LD" >&6; }
  4807. else
  4808. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4809. $as_echo "no" >&6; }
  4810. fi
  4811. if test "x$ac_ct_LD" = x; then
  4812. LD=":"
  4813. else
  4814. case $cross_compiling:$ac_tool_warned in
  4815. yes:)
  4816. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4817. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4818. ac_tool_warned=yes ;;
  4819. esac
  4820. LD=$ac_ct_LD
  4821. fi
  4822. else
  4823. LD="$ac_cv_prog_LD"
  4824. fi
  4825. if test -n "$ac_tool_prefix"; then
  4826. # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
  4827. set dummy ${ac_tool_prefix}ranlib; ac_word=$2
  4828. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4829. $as_echo_n "checking for $ac_word... " >&6; }
  4830. if ${ac_cv_prog_RANLIB+:} false; then :
  4831. $as_echo_n "(cached) " >&6
  4832. else
  4833. if test -n "$RANLIB"; then
  4834. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  4835. else
  4836. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4837. for as_dir in $PATH
  4838. do
  4839. IFS=$as_save_IFS
  4840. test -z "$as_dir" && as_dir=.
  4841. for ac_exec_ext in '' $ac_executable_extensions; do
  4842. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4843. ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
  4844. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4845. break 2
  4846. fi
  4847. done
  4848. done
  4849. IFS=$as_save_IFS
  4850. fi
  4851. fi
  4852. RANLIB=$ac_cv_prog_RANLIB
  4853. if test -n "$RANLIB"; then
  4854. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
  4855. $as_echo "$RANLIB" >&6; }
  4856. else
  4857. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4858. $as_echo "no" >&6; }
  4859. fi
  4860. fi
  4861. if test -z "$ac_cv_prog_RANLIB"; then
  4862. ac_ct_RANLIB=$RANLIB
  4863. # Extract the first word of "ranlib", so it can be a program name with args.
  4864. set dummy ranlib; ac_word=$2
  4865. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4866. $as_echo_n "checking for $ac_word... " >&6; }
  4867. if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
  4868. $as_echo_n "(cached) " >&6
  4869. else
  4870. if test -n "$ac_ct_RANLIB"; then
  4871. ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
  4872. else
  4873. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4874. for as_dir in $PATH
  4875. do
  4876. IFS=$as_save_IFS
  4877. test -z "$as_dir" && as_dir=.
  4878. for ac_exec_ext in '' $ac_executable_extensions; do
  4879. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4880. ac_cv_prog_ac_ct_RANLIB="ranlib"
  4881. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4882. break 2
  4883. fi
  4884. done
  4885. done
  4886. IFS=$as_save_IFS
  4887. fi
  4888. fi
  4889. ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
  4890. if test -n "$ac_ct_RANLIB"; then
  4891. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
  4892. $as_echo "$ac_ct_RANLIB" >&6; }
  4893. else
  4894. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4895. $as_echo "no" >&6; }
  4896. fi
  4897. if test "x$ac_ct_RANLIB" = x; then
  4898. RANLIB=":"
  4899. else
  4900. case $cross_compiling:$ac_tool_warned in
  4901. yes:)
  4902. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  4903. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  4904. ac_tool_warned=yes ;;
  4905. esac
  4906. RANLIB=$ac_ct_RANLIB
  4907. fi
  4908. else
  4909. RANLIB="$ac_cv_prog_RANLIB"
  4910. fi
  4911. fi
  4912. # Checks for programs.
  4913. ac_ext=cpp
  4914. ac_cpp='$CXXCPP $CPPFLAGS'
  4915. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  4916. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  4917. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  4918. if test -z "$CXX"; then
  4919. if test -n "$CCC"; then
  4920. CXX=$CCC
  4921. else
  4922. if test -n "$ac_tool_prefix"; then
  4923. for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
  4924. do
  4925. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  4926. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  4927. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4928. $as_echo_n "checking for $ac_word... " >&6; }
  4929. if ${ac_cv_prog_CXX+:} false; then :
  4930. $as_echo_n "(cached) " >&6
  4931. else
  4932. if test -n "$CXX"; then
  4933. ac_cv_prog_CXX="$CXX" # Let the user override the test.
  4934. else
  4935. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4936. for as_dir in $PATH
  4937. do
  4938. IFS=$as_save_IFS
  4939. test -z "$as_dir" && as_dir=.
  4940. for ac_exec_ext in '' $ac_executable_extensions; do
  4941. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4942. ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
  4943. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4944. break 2
  4945. fi
  4946. done
  4947. done
  4948. IFS=$as_save_IFS
  4949. fi
  4950. fi
  4951. CXX=$ac_cv_prog_CXX
  4952. if test -n "$CXX"; then
  4953. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
  4954. $as_echo "$CXX" >&6; }
  4955. else
  4956. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4957. $as_echo "no" >&6; }
  4958. fi
  4959. test -n "$CXX" && break
  4960. done
  4961. fi
  4962. if test -z "$CXX"; then
  4963. ac_ct_CXX=$CXX
  4964. for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
  4965. do
  4966. # Extract the first word of "$ac_prog", so it can be a program name with args.
  4967. set dummy $ac_prog; ac_word=$2
  4968. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  4969. $as_echo_n "checking for $ac_word... " >&6; }
  4970. if ${ac_cv_prog_ac_ct_CXX+:} false; then :
  4971. $as_echo_n "(cached) " >&6
  4972. else
  4973. if test -n "$ac_ct_CXX"; then
  4974. ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
  4975. else
  4976. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  4977. for as_dir in $PATH
  4978. do
  4979. IFS=$as_save_IFS
  4980. test -z "$as_dir" && as_dir=.
  4981. for ac_exec_ext in '' $ac_executable_extensions; do
  4982. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  4983. ac_cv_prog_ac_ct_CXX="$ac_prog"
  4984. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  4985. break 2
  4986. fi
  4987. done
  4988. done
  4989. IFS=$as_save_IFS
  4990. fi
  4991. fi
  4992. ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
  4993. if test -n "$ac_ct_CXX"; then
  4994. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
  4995. $as_echo "$ac_ct_CXX" >&6; }
  4996. else
  4997. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  4998. $as_echo "no" >&6; }
  4999. fi
  5000. test -n "$ac_ct_CXX" && break
  5001. done
  5002. if test "x$ac_ct_CXX" = x; then
  5003. CXX="g++"
  5004. else
  5005. case $cross_compiling:$ac_tool_warned in
  5006. yes:)
  5007. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5008. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5009. ac_tool_warned=yes ;;
  5010. esac
  5011. CXX=$ac_ct_CXX
  5012. fi
  5013. fi
  5014. fi
  5015. fi
  5016. # Provide some information about the compiler.
  5017. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
  5018. set X $ac_compile
  5019. ac_compiler=$2
  5020. for ac_option in --version -v -V -qversion; do
  5021. { { ac_try="$ac_compiler $ac_option >&5"
  5022. case "(($ac_try" in
  5023. *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  5024. *) ac_try_echo=$ac_try;;
  5025. esac
  5026. eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
  5027. $as_echo "$ac_try_echo"; } >&5
  5028. (eval "$ac_compiler $ac_option >&5") 2>conftest.err
  5029. ac_status=$?
  5030. if test -s conftest.err; then
  5031. sed '10a\
  5032. ... rest of stderr output deleted ...
  5033. 10q' conftest.err >conftest.er1
  5034. cat conftest.er1 >&5
  5035. fi
  5036. rm -f conftest.er1 conftest.err
  5037. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  5038. test $ac_status = 0; }
  5039. done
  5040. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
  5041. $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
  5042. if ${ac_cv_cxx_compiler_gnu+:} false; then :
  5043. $as_echo_n "(cached) " >&6
  5044. else
  5045. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5046. /* end confdefs.h. */
  5047. int
  5048. main ()
  5049. {
  5050. #ifndef __GNUC__
  5051. choke me
  5052. #endif
  5053. ;
  5054. return 0;
  5055. }
  5056. _ACEOF
  5057. if ac_fn_cxx_try_compile "$LINENO"; then :
  5058. ac_compiler_gnu=yes
  5059. else
  5060. ac_compiler_gnu=no
  5061. fi
  5062. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5063. ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
  5064. fi
  5065. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
  5066. $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
  5067. if test $ac_compiler_gnu = yes; then
  5068. GXX=yes
  5069. else
  5070. GXX=
  5071. fi
  5072. ac_test_CXXFLAGS=${CXXFLAGS+set}
  5073. ac_save_CXXFLAGS=$CXXFLAGS
  5074. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
  5075. $as_echo_n "checking whether $CXX accepts -g... " >&6; }
  5076. if ${ac_cv_prog_cxx_g+:} false; then :
  5077. $as_echo_n "(cached) " >&6
  5078. else
  5079. ac_save_cxx_werror_flag=$ac_cxx_werror_flag
  5080. ac_cxx_werror_flag=yes
  5081. ac_cv_prog_cxx_g=no
  5082. CXXFLAGS="-g"
  5083. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5084. /* end confdefs.h. */
  5085. int
  5086. main ()
  5087. {
  5088. ;
  5089. return 0;
  5090. }
  5091. _ACEOF
  5092. if ac_fn_cxx_try_compile "$LINENO"; then :
  5093. ac_cv_prog_cxx_g=yes
  5094. else
  5095. CXXFLAGS=""
  5096. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5097. /* end confdefs.h. */
  5098. int
  5099. main ()
  5100. {
  5101. ;
  5102. return 0;
  5103. }
  5104. _ACEOF
  5105. if ac_fn_cxx_try_compile "$LINENO"; then :
  5106. else
  5107. ac_cxx_werror_flag=$ac_save_cxx_werror_flag
  5108. CXXFLAGS="-g"
  5109. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5110. /* end confdefs.h. */
  5111. int
  5112. main ()
  5113. {
  5114. ;
  5115. return 0;
  5116. }
  5117. _ACEOF
  5118. if ac_fn_cxx_try_compile "$LINENO"; then :
  5119. ac_cv_prog_cxx_g=yes
  5120. fi
  5121. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5122. fi
  5123. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5124. fi
  5125. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  5126. ac_cxx_werror_flag=$ac_save_cxx_werror_flag
  5127. fi
  5128. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
  5129. $as_echo "$ac_cv_prog_cxx_g" >&6; }
  5130. if test "$ac_test_CXXFLAGS" = set; then
  5131. CXXFLAGS=$ac_save_CXXFLAGS
  5132. elif test $ac_cv_prog_cxx_g = yes; then
  5133. if test "$GXX" = yes; then
  5134. CXXFLAGS="-g -O2"
  5135. else
  5136. CXXFLAGS="-g"
  5137. fi
  5138. else
  5139. if test "$GXX" = yes; then
  5140. CXXFLAGS="-O2"
  5141. else
  5142. CXXFLAGS=
  5143. fi
  5144. fi
  5145. ac_ext=c
  5146. ac_cpp='$CPP $CPPFLAGS'
  5147. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5148. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5149. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5150. ac_ext=c
  5151. ac_cpp='$CPP $CPPFLAGS'
  5152. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5153. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5154. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5155. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
  5156. $as_echo_n "checking how to run the C preprocessor... " >&6; }
  5157. # On Suns, sometimes $CPP names a directory.
  5158. if test -n "$CPP" && test -d "$CPP"; then
  5159. CPP=
  5160. fi
  5161. if test -z "$CPP"; then
  5162. if ${ac_cv_prog_CPP+:} false; then :
  5163. $as_echo_n "(cached) " >&6
  5164. else
  5165. # Double quotes because CPP needs to be expanded
  5166. for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
  5167. do
  5168. ac_preproc_ok=false
  5169. for ac_c_preproc_warn_flag in '' yes
  5170. do
  5171. # Use a header file that comes with gcc, so configuring glibc
  5172. # with a fresh cross-compiler works.
  5173. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5174. # <limits.h> exists even on freestanding compilers.
  5175. # On the NeXT, cc -E runs the code through the compiler's parser,
  5176. # not just through cpp. "Syntax error" is here to catch this case.
  5177. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5178. /* end confdefs.h. */
  5179. #ifdef __STDC__
  5180. # include <limits.h>
  5181. #else
  5182. # include <assert.h>
  5183. #endif
  5184. Syntax error
  5185. _ACEOF
  5186. if ac_fn_c_try_cpp "$LINENO"; then :
  5187. else
  5188. # Broken: fails on valid input.
  5189. continue
  5190. fi
  5191. rm -f conftest.err conftest.i conftest.$ac_ext
  5192. # OK, works on sane cases. Now check whether nonexistent headers
  5193. # can be detected and how.
  5194. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5195. /* end confdefs.h. */
  5196. #include <ac_nonexistent.h>
  5197. _ACEOF
  5198. if ac_fn_c_try_cpp "$LINENO"; then :
  5199. # Broken: success on invalid input.
  5200. continue
  5201. else
  5202. # Passes both tests.
  5203. ac_preproc_ok=:
  5204. break
  5205. fi
  5206. rm -f conftest.err conftest.i conftest.$ac_ext
  5207. done
  5208. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5209. rm -f conftest.i conftest.err conftest.$ac_ext
  5210. if $ac_preproc_ok; then :
  5211. break
  5212. fi
  5213. done
  5214. ac_cv_prog_CPP=$CPP
  5215. fi
  5216. CPP=$ac_cv_prog_CPP
  5217. else
  5218. ac_cv_prog_CPP=$CPP
  5219. fi
  5220. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
  5221. $as_echo "$CPP" >&6; }
  5222. ac_preproc_ok=false
  5223. for ac_c_preproc_warn_flag in '' yes
  5224. do
  5225. # Use a header file that comes with gcc, so configuring glibc
  5226. # with a fresh cross-compiler works.
  5227. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5228. # <limits.h> exists even on freestanding compilers.
  5229. # On the NeXT, cc -E runs the code through the compiler's parser,
  5230. # not just through cpp. "Syntax error" is here to catch this case.
  5231. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5232. /* end confdefs.h. */
  5233. #ifdef __STDC__
  5234. # include <limits.h>
  5235. #else
  5236. # include <assert.h>
  5237. #endif
  5238. Syntax error
  5239. _ACEOF
  5240. if ac_fn_c_try_cpp "$LINENO"; then :
  5241. else
  5242. # Broken: fails on valid input.
  5243. continue
  5244. fi
  5245. rm -f conftest.err conftest.i conftest.$ac_ext
  5246. # OK, works on sane cases. Now check whether nonexistent headers
  5247. # can be detected and how.
  5248. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5249. /* end confdefs.h. */
  5250. #include <ac_nonexistent.h>
  5251. _ACEOF
  5252. if ac_fn_c_try_cpp "$LINENO"; then :
  5253. # Broken: success on invalid input.
  5254. continue
  5255. else
  5256. # Passes both tests.
  5257. ac_preproc_ok=:
  5258. break
  5259. fi
  5260. rm -f conftest.err conftest.i conftest.$ac_ext
  5261. done
  5262. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5263. rm -f conftest.i conftest.err conftest.$ac_ext
  5264. if $ac_preproc_ok; then :
  5265. else
  5266. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  5267. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  5268. as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
  5269. See \`config.log' for more details" "$LINENO" 5; }
  5270. fi
  5271. ac_ext=c
  5272. ac_cpp='$CPP $CPPFLAGS'
  5273. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5274. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5275. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5276. ac_ext=cpp
  5277. ac_cpp='$CXXCPP $CPPFLAGS'
  5278. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5279. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5280. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  5281. { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
  5282. $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
  5283. if test -z "$CXXCPP"; then
  5284. if ${ac_cv_prog_CXXCPP+:} false; then :
  5285. $as_echo_n "(cached) " >&6
  5286. else
  5287. # Double quotes because CXXCPP needs to be expanded
  5288. for CXXCPP in "$CXX -E" "/lib/cpp"
  5289. do
  5290. ac_preproc_ok=false
  5291. for ac_cxx_preproc_warn_flag in '' yes
  5292. do
  5293. # Use a header file that comes with gcc, so configuring glibc
  5294. # with a fresh cross-compiler works.
  5295. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5296. # <limits.h> exists even on freestanding compilers.
  5297. # On the NeXT, cc -E runs the code through the compiler's parser,
  5298. # not just through cpp. "Syntax error" is here to catch this case.
  5299. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5300. /* end confdefs.h. */
  5301. #ifdef __STDC__
  5302. # include <limits.h>
  5303. #else
  5304. # include <assert.h>
  5305. #endif
  5306. Syntax error
  5307. _ACEOF
  5308. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5309. else
  5310. # Broken: fails on valid input.
  5311. continue
  5312. fi
  5313. rm -f conftest.err conftest.i conftest.$ac_ext
  5314. # OK, works on sane cases. Now check whether nonexistent headers
  5315. # can be detected and how.
  5316. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5317. /* end confdefs.h. */
  5318. #include <ac_nonexistent.h>
  5319. _ACEOF
  5320. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5321. # Broken: success on invalid input.
  5322. continue
  5323. else
  5324. # Passes both tests.
  5325. ac_preproc_ok=:
  5326. break
  5327. fi
  5328. rm -f conftest.err conftest.i conftest.$ac_ext
  5329. done
  5330. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5331. rm -f conftest.i conftest.err conftest.$ac_ext
  5332. if $ac_preproc_ok; then :
  5333. break
  5334. fi
  5335. done
  5336. ac_cv_prog_CXXCPP=$CXXCPP
  5337. fi
  5338. CXXCPP=$ac_cv_prog_CXXCPP
  5339. else
  5340. ac_cv_prog_CXXCPP=$CXXCPP
  5341. fi
  5342. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
  5343. $as_echo "$CXXCPP" >&6; }
  5344. ac_preproc_ok=false
  5345. for ac_cxx_preproc_warn_flag in '' yes
  5346. do
  5347. # Use a header file that comes with gcc, so configuring glibc
  5348. # with a fresh cross-compiler works.
  5349. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  5350. # <limits.h> exists even on freestanding compilers.
  5351. # On the NeXT, cc -E runs the code through the compiler's parser,
  5352. # not just through cpp. "Syntax error" is here to catch this case.
  5353. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5354. /* end confdefs.h. */
  5355. #ifdef __STDC__
  5356. # include <limits.h>
  5357. #else
  5358. # include <assert.h>
  5359. #endif
  5360. Syntax error
  5361. _ACEOF
  5362. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5363. else
  5364. # Broken: fails on valid input.
  5365. continue
  5366. fi
  5367. rm -f conftest.err conftest.i conftest.$ac_ext
  5368. # OK, works on sane cases. Now check whether nonexistent headers
  5369. # can be detected and how.
  5370. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  5371. /* end confdefs.h. */
  5372. #include <ac_nonexistent.h>
  5373. _ACEOF
  5374. if ac_fn_cxx_try_cpp "$LINENO"; then :
  5375. # Broken: success on invalid input.
  5376. continue
  5377. else
  5378. # Passes both tests.
  5379. ac_preproc_ok=:
  5380. break
  5381. fi
  5382. rm -f conftest.err conftest.i conftest.$ac_ext
  5383. done
  5384. # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
  5385. rm -f conftest.i conftest.err conftest.$ac_ext
  5386. if $ac_preproc_ok; then :
  5387. else
  5388. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  5389. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  5390. as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
  5391. See \`config.log' for more details" "$LINENO" 5; }
  5392. fi
  5393. ac_ext=c
  5394. ac_cpp='$CPP $CPPFLAGS'
  5395. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  5396. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  5397. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  5398. # This macro is just copied into our local acinclude.m4 from libtool.m4 so that
  5399. # the developers regenerating the configure script don't have to install libtool.
  5400. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
  5401. $as_echo_n "checking for a sed that does not truncate output... " >&6; }
  5402. if ${ac_cv_path_SED+:} false; then :
  5403. $as_echo_n "(cached) " >&6
  5404. else
  5405. ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
  5406. for ac_i in 1 2 3 4 5 6 7; do
  5407. ac_script="$ac_script$as_nl$ac_script"
  5408. done
  5409. echo "$ac_script" | sed 99q >conftest.sed
  5410. $as_unset ac_script || ac_script=
  5411. if test -z "$SED"; then
  5412. ac_path_SED_found=false
  5413. # Loop through the user's path and test for each of PROGNAME-LIST
  5414. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5415. for as_dir in $PATH
  5416. do
  5417. IFS=$as_save_IFS
  5418. test -z "$as_dir" && as_dir=.
  5419. for ac_prog in sed gsed; do
  5420. for ac_exec_ext in '' $ac_executable_extensions; do
  5421. ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
  5422. as_fn_executable_p "$ac_path_SED" || continue
  5423. # Check for GNU ac_path_SED and select it if it is found.
  5424. # Check for GNU $ac_path_SED
  5425. case `"$ac_path_SED" --version 2>&1` in
  5426. *GNU*)
  5427. ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
  5428. *)
  5429. ac_count=0
  5430. $as_echo_n 0123456789 >"conftest.in"
  5431. while :
  5432. do
  5433. cat "conftest.in" "conftest.in" >"conftest.tmp"
  5434. mv "conftest.tmp" "conftest.in"
  5435. cp "conftest.in" "conftest.nl"
  5436. $as_echo '' >> "conftest.nl"
  5437. "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
  5438. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  5439. as_fn_arith $ac_count + 1 && ac_count=$as_val
  5440. if test $ac_count -gt ${ac_path_SED_max-0}; then
  5441. # Best one so far, save it but keep looking for a better one
  5442. ac_cv_path_SED="$ac_path_SED"
  5443. ac_path_SED_max=$ac_count
  5444. fi
  5445. # 10*(2^10) chars as input seems more than enough
  5446. test $ac_count -gt 10 && break
  5447. done
  5448. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  5449. esac
  5450. $ac_path_SED_found && break 3
  5451. done
  5452. done
  5453. done
  5454. IFS=$as_save_IFS
  5455. if test -z "$ac_cv_path_SED"; then
  5456. as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
  5457. fi
  5458. else
  5459. ac_cv_path_SED=$SED
  5460. fi
  5461. fi
  5462. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
  5463. $as_echo "$ac_cv_path_SED" >&6; }
  5464. SED="$ac_cv_path_SED"
  5465. rm -f conftest.sed
  5466. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  5467. $as_echo_n "checking for egrep... " >&6; }
  5468. if ${ac_cv_prog_egrep+:} false; then :
  5469. $as_echo_n "(cached) " >&6
  5470. else
  5471. if echo a | (grep -E '(a|b)') >/dev/null 2>&1
  5472. then ac_cv_prog_egrep='grep -E'
  5473. else ac_cv_prog_egrep='egrep'
  5474. fi
  5475. fi
  5476. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_egrep" >&5
  5477. $as_echo "$ac_cv_prog_egrep" >&6; }
  5478. EGREP=$ac_cv_prog_egrep
  5479. # Check whether --with-gnu-ld was given.
  5480. if test "${with_gnu_ld+set}" = set; then :
  5481. withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
  5482. else
  5483. with_gnu_ld=no
  5484. fi
  5485. ac_prog=ld
  5486. if test "$GCC" = yes; then
  5487. # Check if gcc -print-prog-name=ld gives a path.
  5488. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
  5489. $as_echo_n "checking for ld used by $CC... " >&6; }
  5490. case $host in
  5491. *-*-mingw*)
  5492. # gcc leaves a trailing carriage return which upsets mingw
  5493. ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
  5494. *)
  5495. ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
  5496. esac
  5497. case $ac_prog in
  5498. # Accept absolute paths.
  5499. [\\/]* | ?:[\\/]*)
  5500. re_direlt='/[^/][^/]*/\.\./'
  5501. # Canonicalize the pathname of ld
  5502. ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
  5503. while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
  5504. ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
  5505. done
  5506. test -z "$LD" && LD="$ac_prog"
  5507. ;;
  5508. "")
  5509. # If it fails, then pretend we aren't using GCC.
  5510. ac_prog=ld
  5511. ;;
  5512. *)
  5513. # If it is relative, then search for the first ld in PATH.
  5514. with_gnu_ld=unknown
  5515. ;;
  5516. esac
  5517. elif test "$with_gnu_ld" = yes; then
  5518. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
  5519. $as_echo_n "checking for GNU ld... " >&6; }
  5520. else
  5521. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
  5522. $as_echo_n "checking for non-GNU ld... " >&6; }
  5523. fi
  5524. if ${lt_cv_path_LD+:} false; then :
  5525. $as_echo_n "(cached) " >&6
  5526. else
  5527. if test -z "$LD"; then
  5528. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  5529. for ac_dir in $PATH; do
  5530. IFS="$lt_save_ifs"
  5531. test -z "$ac_dir" && ac_dir=.
  5532. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
  5533. lt_cv_path_LD="$ac_dir/$ac_prog"
  5534. # Check to see if the program is GNU ld. I'd rather use --version,
  5535. # but apparently some variants of GNU ld only accept -v.
  5536. # Break only if it was the GNU/non-GNU ld that we prefer.
  5537. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
  5538. *GNU* | *'with BFD'*)
  5539. test "$with_gnu_ld" != no && break
  5540. ;;
  5541. *)
  5542. test "$with_gnu_ld" != yes && break
  5543. ;;
  5544. esac
  5545. fi
  5546. done
  5547. IFS="$lt_save_ifs"
  5548. else
  5549. lt_cv_path_LD="$LD" # Let the user override the test with a path.
  5550. fi
  5551. fi
  5552. LD="$lt_cv_path_LD"
  5553. if test -n "$LD"; then
  5554. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
  5555. $as_echo "$LD" >&6; }
  5556. else
  5557. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5558. $as_echo "no" >&6; }
  5559. fi
  5560. test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
  5561. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
  5562. $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
  5563. if ${lt_cv_prog_gnu_ld+:} false; then :
  5564. $as_echo_n "(cached) " >&6
  5565. else
  5566. # I'd rather use --version here, but apparently some GNU lds only accept -v.
  5567. case `$LD -v 2>&1 </dev/null` in
  5568. *GNU* | *'with BFD'*)
  5569. lt_cv_prog_gnu_ld=yes
  5570. ;;
  5571. *)
  5572. lt_cv_prog_gnu_ld=no
  5573. ;;
  5574. esac
  5575. fi
  5576. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
  5577. $as_echo "$lt_cv_prog_gnu_ld" >&6; }
  5578. with_gnu_ld=$lt_cv_prog_gnu_ld
  5579. # note, does not work on FreeBSD
  5580. for ac_prog in gawk mawk nawk awk
  5581. do
  5582. # Extract the first word of "$ac_prog", so it can be a program name with args.
  5583. set dummy $ac_prog; ac_word=$2
  5584. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5585. $as_echo_n "checking for $ac_word... " >&6; }
  5586. if ${ac_cv_prog_AWK+:} false; then :
  5587. $as_echo_n "(cached) " >&6
  5588. else
  5589. if test -n "$AWK"; then
  5590. ac_cv_prog_AWK="$AWK" # Let the user override the test.
  5591. else
  5592. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5593. for as_dir in $PATH
  5594. do
  5595. IFS=$as_save_IFS
  5596. test -z "$as_dir" && as_dir=.
  5597. for ac_exec_ext in '' $ac_executable_extensions; do
  5598. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5599. ac_cv_prog_AWK="$ac_prog"
  5600. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5601. break 2
  5602. fi
  5603. done
  5604. done
  5605. IFS=$as_save_IFS
  5606. fi
  5607. fi
  5608. AWK=$ac_cv_prog_AWK
  5609. if test -n "$AWK"; then
  5610. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
  5611. $as_echo "$AWK" >&6; }
  5612. else
  5613. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5614. $as_echo "no" >&6; }
  5615. fi
  5616. test -n "$AWK" && break
  5617. done
  5618. # Find a good install program. We prefer a C program (faster),
  5619. # so one script is as good as another. But avoid the broken or
  5620. # incompatible versions:
  5621. # SysV /etc/install, /usr/sbin/install
  5622. # SunOS /usr/etc/install
  5623. # IRIX /sbin/install
  5624. # AIX /bin/install
  5625. # AmigaOS /C/install, which installs bootblocks on floppy discs
  5626. # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
  5627. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  5628. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  5629. # OS/2's system install, which has a completely different semantic
  5630. # ./install, which can be erroneously created by make from ./install.sh.
  5631. # Reject install programs that cannot install multiple files.
  5632. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
  5633. $as_echo_n "checking for a BSD-compatible install... " >&6; }
  5634. if test -z "$INSTALL"; then
  5635. if ${ac_cv_path_install+:} false; then :
  5636. $as_echo_n "(cached) " >&6
  5637. else
  5638. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5639. for as_dir in $PATH
  5640. do
  5641. IFS=$as_save_IFS
  5642. test -z "$as_dir" && as_dir=.
  5643. # Account for people who put trailing slashes in PATH elements.
  5644. case $as_dir/ in #((
  5645. ./ | .// | /[cC]/* | \
  5646. /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
  5647. ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
  5648. /usr/ucb/* ) ;;
  5649. *)
  5650. # OSF1 and SCO ODT 3.0 have their own names for install.
  5651. # Don't use installbsd from OSF since it installs stuff as root
  5652. # by default.
  5653. for ac_prog in ginstall scoinst install; do
  5654. for ac_exec_ext in '' $ac_executable_extensions; do
  5655. if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
  5656. if test $ac_prog = install &&
  5657. grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
  5658. # AIX install. It has an incompatible calling convention.
  5659. :
  5660. elif test $ac_prog = install &&
  5661. grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
  5662. # program-specific install script used by HP pwplus--don't use.
  5663. :
  5664. else
  5665. rm -rf conftest.one conftest.two conftest.dir
  5666. echo one > conftest.one
  5667. echo two > conftest.two
  5668. mkdir conftest.dir
  5669. if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
  5670. test -s conftest.one && test -s conftest.two &&
  5671. test -s conftest.dir/conftest.one &&
  5672. test -s conftest.dir/conftest.two
  5673. then
  5674. ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
  5675. break 3
  5676. fi
  5677. fi
  5678. fi
  5679. done
  5680. done
  5681. ;;
  5682. esac
  5683. done
  5684. IFS=$as_save_IFS
  5685. rm -rf conftest.one conftest.two conftest.dir
  5686. fi
  5687. if test "${ac_cv_path_install+set}" = set; then
  5688. INSTALL=$ac_cv_path_install
  5689. else
  5690. # As a last resort, use the slow shell script. Don't cache a
  5691. # value for INSTALL within a source directory, because that will
  5692. # break other packages using the cache if that directory is
  5693. # removed, or if the value is a relative name.
  5694. INSTALL=$ac_install_sh
  5695. fi
  5696. fi
  5697. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
  5698. $as_echo "$INSTALL" >&6; }
  5699. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  5700. # It thinks the first close brace ends the variable substitution.
  5701. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  5702. test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
  5703. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  5704. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
  5705. $as_echo_n "checking whether ln -s works... " >&6; }
  5706. LN_S=$as_ln_s
  5707. if test "$LN_S" = "ln -s"; then
  5708. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  5709. $as_echo "yes" >&6; }
  5710. else
  5711. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
  5712. $as_echo "no, using $LN_S" >&6; }
  5713. fi
  5714. if test -n "$ac_tool_prefix"; then
  5715. # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
  5716. set dummy ${ac_tool_prefix}ranlib; ac_word=$2
  5717. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5718. $as_echo_n "checking for $ac_word... " >&6; }
  5719. if ${ac_cv_prog_RANLIB+:} false; then :
  5720. $as_echo_n "(cached) " >&6
  5721. else
  5722. if test -n "$RANLIB"; then
  5723. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  5724. else
  5725. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5726. for as_dir in $PATH
  5727. do
  5728. IFS=$as_save_IFS
  5729. test -z "$as_dir" && as_dir=.
  5730. for ac_exec_ext in '' $ac_executable_extensions; do
  5731. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5732. ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
  5733. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5734. break 2
  5735. fi
  5736. done
  5737. done
  5738. IFS=$as_save_IFS
  5739. fi
  5740. fi
  5741. RANLIB=$ac_cv_prog_RANLIB
  5742. if test -n "$RANLIB"; then
  5743. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
  5744. $as_echo "$RANLIB" >&6; }
  5745. else
  5746. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5747. $as_echo "no" >&6; }
  5748. fi
  5749. fi
  5750. if test -z "$ac_cv_prog_RANLIB"; then
  5751. ac_ct_RANLIB=$RANLIB
  5752. # Extract the first word of "ranlib", so it can be a program name with args.
  5753. set dummy ranlib; ac_word=$2
  5754. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5755. $as_echo_n "checking for $ac_word... " >&6; }
  5756. if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
  5757. $as_echo_n "(cached) " >&6
  5758. else
  5759. if test -n "$ac_ct_RANLIB"; then
  5760. ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
  5761. else
  5762. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5763. for as_dir in $PATH
  5764. do
  5765. IFS=$as_save_IFS
  5766. test -z "$as_dir" && as_dir=.
  5767. for ac_exec_ext in '' $ac_executable_extensions; do
  5768. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5769. ac_cv_prog_ac_ct_RANLIB="ranlib"
  5770. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5771. break 2
  5772. fi
  5773. done
  5774. done
  5775. IFS=$as_save_IFS
  5776. fi
  5777. fi
  5778. ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
  5779. if test -n "$ac_ct_RANLIB"; then
  5780. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
  5781. $as_echo "$ac_ct_RANLIB" >&6; }
  5782. else
  5783. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5784. $as_echo "no" >&6; }
  5785. fi
  5786. if test "x$ac_ct_RANLIB" = x; then
  5787. RANLIB=":"
  5788. else
  5789. case $cross_compiling:$ac_tool_warned in
  5790. yes:)
  5791. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5792. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5793. ac_tool_warned=yes ;;
  5794. esac
  5795. RANLIB=$ac_ct_RANLIB
  5796. fi
  5797. else
  5798. RANLIB="$ac_cv_prog_RANLIB"
  5799. fi
  5800. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU make" >&5
  5801. $as_echo_n "checking for GNU make... " >&6; }
  5802. if ${ac_cv_GNU_MAKE+:} false; then :
  5803. $as_echo_n "(cached) " >&6
  5804. else
  5805. ac_cv_GNU_MAKE='Not Found' ;
  5806. ac_cv_GNU_MAKE_VERSION_MAJOR=0 ;
  5807. ac_cv_GNU_MAKE_VERSION_MINOR=0 ;
  5808. for a in make gmake gnumake ; do
  5809. if test -z "$a" ; then continue ; fi ;
  5810. if ( sh -c "$a --version" 2> /dev/null | grep GNU 2>&1 > /dev/null ) ; then
  5811. ac_cv_GNU_MAKE=$a ;
  5812. ac_cv_GNU_MAKE_VERSION_MAJOR=`$ac_cv_GNU_MAKE --version | grep "GNU Make" | cut -f3 -d' ' | cut -f1 -d'.'`
  5813. ac_cv_GNU_MAKE_VERSION_MINOR=`$ac_cv_GNU_MAKE --version | grep "GNU Make" | cut -f2 -d'.' | cut -c1-2`
  5814. break;
  5815. fi
  5816. done ;
  5817. fi
  5818. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_GNU_MAKE" >&5
  5819. $as_echo "$ac_cv_GNU_MAKE" >&6; } ;
  5820. if test "x$ac_cv_GNU_MAKE" = "xNot Found" ; then
  5821. as_fn_error $? "*** Please install GNU make. It is required to build Asterisk!" "$LINENO" 5
  5822. exit 1
  5823. fi
  5824. GNU_MAKE=$ac_cv_GNU_MAKE
  5825. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
  5826. $as_echo_n "checking for egrep... " >&6; }
  5827. if ${ac_cv_path_EGREP+:} false; then :
  5828. $as_echo_n "(cached) " >&6
  5829. else
  5830. if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
  5831. then ac_cv_path_EGREP="$GREP -E"
  5832. else
  5833. if test -z "$EGREP"; then
  5834. ac_path_EGREP_found=false
  5835. # Loop through the user's path and test for each of PROGNAME-LIST
  5836. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5837. for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
  5838. do
  5839. IFS=$as_save_IFS
  5840. test -z "$as_dir" && as_dir=.
  5841. for ac_prog in egrep; do
  5842. for ac_exec_ext in '' $ac_executable_extensions; do
  5843. ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
  5844. as_fn_executable_p "$ac_path_EGREP" || continue
  5845. # Check for GNU ac_path_EGREP and select it if it is found.
  5846. # Check for GNU $ac_path_EGREP
  5847. case `"$ac_path_EGREP" --version 2>&1` in
  5848. *GNU*)
  5849. ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
  5850. *)
  5851. ac_count=0
  5852. $as_echo_n 0123456789 >"conftest.in"
  5853. while :
  5854. do
  5855. cat "conftest.in" "conftest.in" >"conftest.tmp"
  5856. mv "conftest.tmp" "conftest.in"
  5857. cp "conftest.in" "conftest.nl"
  5858. $as_echo 'EGREP' >> "conftest.nl"
  5859. "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
  5860. diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
  5861. as_fn_arith $ac_count + 1 && ac_count=$as_val
  5862. if test $ac_count -gt ${ac_path_EGREP_max-0}; then
  5863. # Best one so far, save it but keep looking for a better one
  5864. ac_cv_path_EGREP="$ac_path_EGREP"
  5865. ac_path_EGREP_max=$ac_count
  5866. fi
  5867. # 10*(2^10) chars as input seems more than enough
  5868. test $ac_count -gt 10 && break
  5869. done
  5870. rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
  5871. esac
  5872. $ac_path_EGREP_found && break 3
  5873. done
  5874. done
  5875. done
  5876. IFS=$as_save_IFS
  5877. if test -z "$ac_cv_path_EGREP"; then
  5878. as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
  5879. fi
  5880. else
  5881. ac_cv_path_EGREP=$EGREP
  5882. fi
  5883. fi
  5884. fi
  5885. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
  5886. $as_echo "$ac_cv_path_EGREP" >&6; }
  5887. EGREP="$ac_cv_path_EGREP"
  5888. if test -n "$ac_tool_prefix"; then
  5889. for ac_prog in strip gstrip
  5890. do
  5891. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  5892. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  5893. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5894. $as_echo_n "checking for $ac_word... " >&6; }
  5895. if ${ac_cv_prog_STRIP+:} false; then :
  5896. $as_echo_n "(cached) " >&6
  5897. else
  5898. if test -n "$STRIP"; then
  5899. ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
  5900. else
  5901. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5902. for as_dir in $PATH
  5903. do
  5904. IFS=$as_save_IFS
  5905. test -z "$as_dir" && as_dir=.
  5906. for ac_exec_ext in '' $ac_executable_extensions; do
  5907. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5908. ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog"
  5909. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5910. break 2
  5911. fi
  5912. done
  5913. done
  5914. IFS=$as_save_IFS
  5915. fi
  5916. fi
  5917. STRIP=$ac_cv_prog_STRIP
  5918. if test -n "$STRIP"; then
  5919. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
  5920. $as_echo "$STRIP" >&6; }
  5921. else
  5922. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5923. $as_echo "no" >&6; }
  5924. fi
  5925. test -n "$STRIP" && break
  5926. done
  5927. fi
  5928. if test -z "$STRIP"; then
  5929. ac_ct_STRIP=$STRIP
  5930. for ac_prog in strip gstrip
  5931. do
  5932. # Extract the first word of "$ac_prog", so it can be a program name with args.
  5933. set dummy $ac_prog; ac_word=$2
  5934. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5935. $as_echo_n "checking for $ac_word... " >&6; }
  5936. if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
  5937. $as_echo_n "(cached) " >&6
  5938. else
  5939. if test -n "$ac_ct_STRIP"; then
  5940. ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
  5941. else
  5942. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5943. for as_dir in $PATH
  5944. do
  5945. IFS=$as_save_IFS
  5946. test -z "$as_dir" && as_dir=.
  5947. for ac_exec_ext in '' $ac_executable_extensions; do
  5948. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  5949. ac_cv_prog_ac_ct_STRIP="$ac_prog"
  5950. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  5951. break 2
  5952. fi
  5953. done
  5954. done
  5955. IFS=$as_save_IFS
  5956. fi
  5957. fi
  5958. ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
  5959. if test -n "$ac_ct_STRIP"; then
  5960. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
  5961. $as_echo "$ac_ct_STRIP" >&6; }
  5962. else
  5963. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  5964. $as_echo "no" >&6; }
  5965. fi
  5966. test -n "$ac_ct_STRIP" && break
  5967. done
  5968. if test "x$ac_ct_STRIP" = x; then
  5969. STRIP=":"
  5970. else
  5971. case $cross_compiling:$ac_tool_warned in
  5972. yes:)
  5973. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  5974. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  5975. ac_tool_warned=yes ;;
  5976. esac
  5977. STRIP=$ac_ct_STRIP
  5978. fi
  5979. fi
  5980. if test -n "$ac_tool_prefix"; then
  5981. for ac_prog in ar gar
  5982. do
  5983. # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
  5984. set dummy $ac_tool_prefix$ac_prog; ac_word=$2
  5985. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  5986. $as_echo_n "checking for $ac_word... " >&6; }
  5987. if ${ac_cv_prog_AR+:} false; then :
  5988. $as_echo_n "(cached) " >&6
  5989. else
  5990. if test -n "$AR"; then
  5991. ac_cv_prog_AR="$AR" # Let the user override the test.
  5992. else
  5993. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  5994. for as_dir in $PATH
  5995. do
  5996. IFS=$as_save_IFS
  5997. test -z "$as_dir" && as_dir=.
  5998. for ac_exec_ext in '' $ac_executable_extensions; do
  5999. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6000. ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
  6001. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6002. break 2
  6003. fi
  6004. done
  6005. done
  6006. IFS=$as_save_IFS
  6007. fi
  6008. fi
  6009. AR=$ac_cv_prog_AR
  6010. if test -n "$AR"; then
  6011. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
  6012. $as_echo "$AR" >&6; }
  6013. else
  6014. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6015. $as_echo "no" >&6; }
  6016. fi
  6017. test -n "$AR" && break
  6018. done
  6019. fi
  6020. if test -z "$AR"; then
  6021. ac_ct_AR=$AR
  6022. for ac_prog in ar gar
  6023. do
  6024. # Extract the first word of "$ac_prog", so it can be a program name with args.
  6025. set dummy $ac_prog; ac_word=$2
  6026. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6027. $as_echo_n "checking for $ac_word... " >&6; }
  6028. if ${ac_cv_prog_ac_ct_AR+:} false; then :
  6029. $as_echo_n "(cached) " >&6
  6030. else
  6031. if test -n "$ac_ct_AR"; then
  6032. ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
  6033. else
  6034. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6035. for as_dir in $PATH
  6036. do
  6037. IFS=$as_save_IFS
  6038. test -z "$as_dir" && as_dir=.
  6039. for ac_exec_ext in '' $ac_executable_extensions; do
  6040. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6041. ac_cv_prog_ac_ct_AR="$ac_prog"
  6042. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6043. break 2
  6044. fi
  6045. done
  6046. done
  6047. IFS=$as_save_IFS
  6048. fi
  6049. fi
  6050. ac_ct_AR=$ac_cv_prog_ac_ct_AR
  6051. if test -n "$ac_ct_AR"; then
  6052. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
  6053. $as_echo "$ac_ct_AR" >&6; }
  6054. else
  6055. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6056. $as_echo "no" >&6; }
  6057. fi
  6058. test -n "$ac_ct_AR" && break
  6059. done
  6060. if test "x$ac_ct_AR" = x; then
  6061. AR=":"
  6062. else
  6063. case $cross_compiling:$ac_tool_warned in
  6064. yes:)
  6065. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  6066. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  6067. ac_tool_warned=yes ;;
  6068. esac
  6069. AR=$ac_ct_AR
  6070. fi
  6071. fi
  6072. GNU_LD=0
  6073. if test "x$with_gnu_ld" = "xyes" ; then
  6074. GNU_LD=1
  6075. fi
  6076. # Extract the first word of "bison", so it can be a program name with args.
  6077. set dummy bison; ac_word=$2
  6078. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6079. $as_echo_n "checking for $ac_word... " >&6; }
  6080. if ${ac_cv_path_BISON+:} false; then :
  6081. $as_echo_n "(cached) " >&6
  6082. else
  6083. case $BISON in
  6084. [\\/]* | ?:[\\/]*)
  6085. ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
  6086. ;;
  6087. *)
  6088. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6089. for as_dir in $PATH
  6090. do
  6091. IFS=$as_save_IFS
  6092. test -z "$as_dir" && as_dir=.
  6093. for ac_exec_ext in '' $ac_executable_extensions; do
  6094. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6095. ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
  6096. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6097. break 2
  6098. fi
  6099. done
  6100. done
  6101. IFS=$as_save_IFS
  6102. test -z "$ac_cv_path_BISON" && ac_cv_path_BISON=":"
  6103. ;;
  6104. esac
  6105. fi
  6106. BISON=$ac_cv_path_BISON
  6107. if test -n "$BISON"; then
  6108. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
  6109. $as_echo "$BISON" >&6; }
  6110. else
  6111. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6112. $as_echo "no" >&6; }
  6113. fi
  6114. # Extract the first word of "cmp", so it can be a program name with args.
  6115. set dummy cmp; ac_word=$2
  6116. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6117. $as_echo_n "checking for $ac_word... " >&6; }
  6118. if ${ac_cv_path_CMP+:} false; then :
  6119. $as_echo_n "(cached) " >&6
  6120. else
  6121. case $CMP in
  6122. [\\/]* | ?:[\\/]*)
  6123. ac_cv_path_CMP="$CMP" # Let the user override the test with a path.
  6124. ;;
  6125. *)
  6126. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6127. for as_dir in $PATH
  6128. do
  6129. IFS=$as_save_IFS
  6130. test -z "$as_dir" && as_dir=.
  6131. for ac_exec_ext in '' $ac_executable_extensions; do
  6132. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6133. ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext"
  6134. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6135. break 2
  6136. fi
  6137. done
  6138. done
  6139. IFS=$as_save_IFS
  6140. test -z "$ac_cv_path_CMP" && ac_cv_path_CMP=":"
  6141. ;;
  6142. esac
  6143. fi
  6144. CMP=$ac_cv_path_CMP
  6145. if test -n "$CMP"; then
  6146. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5
  6147. $as_echo "$CMP" >&6; }
  6148. else
  6149. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6150. $as_echo "no" >&6; }
  6151. fi
  6152. # Extract the first word of "flex", so it can be a program name with args.
  6153. set dummy flex; ac_word=$2
  6154. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6155. $as_echo_n "checking for $ac_word... " >&6; }
  6156. if ${ac_cv_path_FLEX+:} false; then :
  6157. $as_echo_n "(cached) " >&6
  6158. else
  6159. case $FLEX in
  6160. [\\/]* | ?:[\\/]*)
  6161. ac_cv_path_FLEX="$FLEX" # Let the user override the test with a path.
  6162. ;;
  6163. *)
  6164. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6165. for as_dir in $PATH
  6166. do
  6167. IFS=$as_save_IFS
  6168. test -z "$as_dir" && as_dir=.
  6169. for ac_exec_ext in '' $ac_executable_extensions; do
  6170. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6171. ac_cv_path_FLEX="$as_dir/$ac_word$ac_exec_ext"
  6172. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6173. break 2
  6174. fi
  6175. done
  6176. done
  6177. IFS=$as_save_IFS
  6178. test -z "$ac_cv_path_FLEX" && ac_cv_path_FLEX=":"
  6179. ;;
  6180. esac
  6181. fi
  6182. FLEX=$ac_cv_path_FLEX
  6183. if test -n "$FLEX"; then
  6184. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLEX" >&5
  6185. $as_echo "$FLEX" >&6; }
  6186. else
  6187. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6188. $as_echo "no" >&6; }
  6189. fi
  6190. # Extract the first word of "grep", so it can be a program name with args.
  6191. set dummy grep; ac_word=$2
  6192. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6193. $as_echo_n "checking for $ac_word... " >&6; }
  6194. if ${ac_cv_path_GREP+:} false; then :
  6195. $as_echo_n "(cached) " >&6
  6196. else
  6197. case $GREP in
  6198. [\\/]* | ?:[\\/]*)
  6199. ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
  6200. ;;
  6201. *)
  6202. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6203. for as_dir in $PATH
  6204. do
  6205. IFS=$as_save_IFS
  6206. test -z "$as_dir" && as_dir=.
  6207. for ac_exec_ext in '' $ac_executable_extensions; do
  6208. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6209. ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
  6210. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6211. break 2
  6212. fi
  6213. done
  6214. done
  6215. IFS=$as_save_IFS
  6216. test -z "$ac_cv_path_GREP" && ac_cv_path_GREP=":"
  6217. ;;
  6218. esac
  6219. fi
  6220. GREP=$ac_cv_path_GREP
  6221. if test -n "$GREP"; then
  6222. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
  6223. $as_echo "$GREP" >&6; }
  6224. else
  6225. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6226. $as_echo "no" >&6; }
  6227. fi
  6228. # Extract the first word of "python", so it can be a program name with args.
  6229. set dummy python; ac_word=$2
  6230. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6231. $as_echo_n "checking for $ac_word... " >&6; }
  6232. if ${ac_cv_path_PYTHON+:} false; then :
  6233. $as_echo_n "(cached) " >&6
  6234. else
  6235. case $PYTHON in
  6236. [\\/]* | ?:[\\/]*)
  6237. ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
  6238. ;;
  6239. *)
  6240. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6241. for as_dir in $PATH
  6242. do
  6243. IFS=$as_save_IFS
  6244. test -z "$as_dir" && as_dir=.
  6245. for ac_exec_ext in '' $ac_executable_extensions; do
  6246. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6247. ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
  6248. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6249. break 2
  6250. fi
  6251. done
  6252. done
  6253. IFS=$as_save_IFS
  6254. test -z "$ac_cv_path_PYTHON" && ac_cv_path_PYTHON=":"
  6255. ;;
  6256. esac
  6257. fi
  6258. PYTHON=$ac_cv_path_PYTHON
  6259. if test -n "$PYTHON"; then
  6260. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
  6261. $as_echo "$PYTHON" >&6; }
  6262. else
  6263. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6264. $as_echo "no" >&6; }
  6265. fi
  6266. # Extract the first word of "find", so it can be a program name with args.
  6267. set dummy find; ac_word=$2
  6268. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6269. $as_echo_n "checking for $ac_word... " >&6; }
  6270. if ${ac_cv_path_FIND+:} false; then :
  6271. $as_echo_n "(cached) " >&6
  6272. else
  6273. case $FIND in
  6274. [\\/]* | ?:[\\/]*)
  6275. ac_cv_path_FIND="$FIND" # Let the user override the test with a path.
  6276. ;;
  6277. *)
  6278. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6279. for as_dir in $PATH
  6280. do
  6281. IFS=$as_save_IFS
  6282. test -z "$as_dir" && as_dir=.
  6283. for ac_exec_ext in '' $ac_executable_extensions; do
  6284. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6285. ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext"
  6286. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6287. break 2
  6288. fi
  6289. done
  6290. done
  6291. IFS=$as_save_IFS
  6292. test -z "$ac_cv_path_FIND" && ac_cv_path_FIND=":"
  6293. ;;
  6294. esac
  6295. fi
  6296. FIND=$ac_cv_path_FIND
  6297. if test -n "$FIND"; then
  6298. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5
  6299. $as_echo "$FIND" >&6; }
  6300. else
  6301. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6302. $as_echo "no" >&6; }
  6303. fi
  6304. # Extract the first word of "compress", so it can be a program name with args.
  6305. set dummy compress; ac_word=$2
  6306. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6307. $as_echo_n "checking for $ac_word... " >&6; }
  6308. if ${ac_cv_path_COMPRESS+:} false; then :
  6309. $as_echo_n "(cached) " >&6
  6310. else
  6311. case $COMPRESS in
  6312. [\\/]* | ?:[\\/]*)
  6313. ac_cv_path_COMPRESS="$COMPRESS" # Let the user override the test with a path.
  6314. ;;
  6315. *)
  6316. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6317. for as_dir in $PATH
  6318. do
  6319. IFS=$as_save_IFS
  6320. test -z "$as_dir" && as_dir=.
  6321. for ac_exec_ext in '' $ac_executable_extensions; do
  6322. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6323. ac_cv_path_COMPRESS="$as_dir/$ac_word$ac_exec_ext"
  6324. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6325. break 2
  6326. fi
  6327. done
  6328. done
  6329. IFS=$as_save_IFS
  6330. test -z "$ac_cv_path_COMPRESS" && ac_cv_path_COMPRESS=":"
  6331. ;;
  6332. esac
  6333. fi
  6334. COMPRESS=$ac_cv_path_COMPRESS
  6335. if test -n "$COMPRESS"; then
  6336. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPRESS" >&5
  6337. $as_echo "$COMPRESS" >&6; }
  6338. else
  6339. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6340. $as_echo "no" >&6; }
  6341. fi
  6342. # Extract the first word of "basename", so it can be a program name with args.
  6343. set dummy basename; ac_word=$2
  6344. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6345. $as_echo_n "checking for $ac_word... " >&6; }
  6346. if ${ac_cv_path_BASENAME+:} false; then :
  6347. $as_echo_n "(cached) " >&6
  6348. else
  6349. case $BASENAME in
  6350. [\\/]* | ?:[\\/]*)
  6351. ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path.
  6352. ;;
  6353. *)
  6354. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6355. for as_dir in $PATH
  6356. do
  6357. IFS=$as_save_IFS
  6358. test -z "$as_dir" && as_dir=.
  6359. for ac_exec_ext in '' $ac_executable_extensions; do
  6360. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6361. ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext"
  6362. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6363. break 2
  6364. fi
  6365. done
  6366. done
  6367. IFS=$as_save_IFS
  6368. test -z "$ac_cv_path_BASENAME" && ac_cv_path_BASENAME=":"
  6369. ;;
  6370. esac
  6371. fi
  6372. BASENAME=$ac_cv_path_BASENAME
  6373. if test -n "$BASENAME"; then
  6374. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5
  6375. $as_echo "$BASENAME" >&6; }
  6376. else
  6377. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6378. $as_echo "no" >&6; }
  6379. fi
  6380. # Extract the first word of "dirname", so it can be a program name with args.
  6381. set dummy dirname; ac_word=$2
  6382. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6383. $as_echo_n "checking for $ac_word... " >&6; }
  6384. if ${ac_cv_path_DIRNAME+:} false; then :
  6385. $as_echo_n "(cached) " >&6
  6386. else
  6387. case $DIRNAME in
  6388. [\\/]* | ?:[\\/]*)
  6389. ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path.
  6390. ;;
  6391. *)
  6392. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6393. for as_dir in $PATH
  6394. do
  6395. IFS=$as_save_IFS
  6396. test -z "$as_dir" && as_dir=.
  6397. for ac_exec_ext in '' $ac_executable_extensions; do
  6398. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6399. ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext"
  6400. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6401. break 2
  6402. fi
  6403. done
  6404. done
  6405. IFS=$as_save_IFS
  6406. test -z "$ac_cv_path_DIRNAME" && ac_cv_path_DIRNAME=":"
  6407. ;;
  6408. esac
  6409. fi
  6410. DIRNAME=$ac_cv_path_DIRNAME
  6411. if test -n "$DIRNAME"; then
  6412. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5
  6413. $as_echo "$DIRNAME" >&6; }
  6414. else
  6415. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6416. $as_echo "no" >&6; }
  6417. fi
  6418. # Extract the first word of "sh", so it can be a program name with args.
  6419. set dummy sh; ac_word=$2
  6420. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6421. $as_echo_n "checking for $ac_word... " >&6; }
  6422. if ${ac_cv_path_SHELL+:} false; then :
  6423. $as_echo_n "(cached) " >&6
  6424. else
  6425. case $SHELL in
  6426. [\\/]* | ?:[\\/]*)
  6427. ac_cv_path_SHELL="$SHELL" # Let the user override the test with a path.
  6428. ;;
  6429. *)
  6430. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6431. for as_dir in $PATH
  6432. do
  6433. IFS=$as_save_IFS
  6434. test -z "$as_dir" && as_dir=.
  6435. for ac_exec_ext in '' $ac_executable_extensions; do
  6436. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6437. ac_cv_path_SHELL="$as_dir/$ac_word$ac_exec_ext"
  6438. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6439. break 2
  6440. fi
  6441. done
  6442. done
  6443. IFS=$as_save_IFS
  6444. test -z "$ac_cv_path_SHELL" && ac_cv_path_SHELL=":"
  6445. ;;
  6446. esac
  6447. fi
  6448. SHELL=$ac_cv_path_SHELL
  6449. if test -n "$SHELL"; then
  6450. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHELL" >&5
  6451. $as_echo "$SHELL" >&6; }
  6452. else
  6453. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6454. $as_echo "no" >&6; }
  6455. fi
  6456. # Extract the first word of "ln", so it can be a program name with args.
  6457. set dummy ln; ac_word=$2
  6458. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6459. $as_echo_n "checking for $ac_word... " >&6; }
  6460. if ${ac_cv_path_LN+:} false; then :
  6461. $as_echo_n "(cached) " >&6
  6462. else
  6463. case $LN in
  6464. [\\/]* | ?:[\\/]*)
  6465. ac_cv_path_LN="$LN" # Let the user override the test with a path.
  6466. ;;
  6467. *)
  6468. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6469. for as_dir in $PATH
  6470. do
  6471. IFS=$as_save_IFS
  6472. test -z "$as_dir" && as_dir=.
  6473. for ac_exec_ext in '' $ac_executable_extensions; do
  6474. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6475. ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext"
  6476. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6477. break 2
  6478. fi
  6479. done
  6480. done
  6481. IFS=$as_save_IFS
  6482. test -z "$ac_cv_path_LN" && ac_cv_path_LN=":"
  6483. ;;
  6484. esac
  6485. fi
  6486. LN=$ac_cv_path_LN
  6487. if test -n "$LN"; then
  6488. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5
  6489. $as_echo "$LN" >&6; }
  6490. else
  6491. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6492. $as_echo "no" >&6; }
  6493. fi
  6494. # Extract the first word of "doxygen", so it can be a program name with args.
  6495. set dummy doxygen; ac_word=$2
  6496. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6497. $as_echo_n "checking for $ac_word... " >&6; }
  6498. if ${ac_cv_path_DOXYGEN+:} false; then :
  6499. $as_echo_n "(cached) " >&6
  6500. else
  6501. case $DOXYGEN in
  6502. [\\/]* | ?:[\\/]*)
  6503. ac_cv_path_DOXYGEN="$DOXYGEN" # Let the user override the test with a path.
  6504. ;;
  6505. *)
  6506. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6507. for as_dir in $PATH
  6508. do
  6509. IFS=$as_save_IFS
  6510. test -z "$as_dir" && as_dir=.
  6511. for ac_exec_ext in '' $ac_executable_extensions; do
  6512. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6513. ac_cv_path_DOXYGEN="$as_dir/$ac_word$ac_exec_ext"
  6514. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6515. break 2
  6516. fi
  6517. done
  6518. done
  6519. IFS=$as_save_IFS
  6520. test -z "$ac_cv_path_DOXYGEN" && ac_cv_path_DOXYGEN=":"
  6521. ;;
  6522. esac
  6523. fi
  6524. DOXYGEN=$ac_cv_path_DOXYGEN
  6525. if test -n "$DOXYGEN"; then
  6526. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOXYGEN" >&5
  6527. $as_echo "$DOXYGEN" >&6; }
  6528. else
  6529. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6530. $as_echo "no" >&6; }
  6531. fi
  6532. # Extract the first word of "dot", so it can be a program name with args.
  6533. set dummy dot; ac_word=$2
  6534. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6535. $as_echo_n "checking for $ac_word... " >&6; }
  6536. if ${ac_cv_path_DOT+:} false; then :
  6537. $as_echo_n "(cached) " >&6
  6538. else
  6539. case $DOT in
  6540. [\\/]* | ?:[\\/]*)
  6541. ac_cv_path_DOT="$DOT" # Let the user override the test with a path.
  6542. ;;
  6543. *)
  6544. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6545. for as_dir in $PATH
  6546. do
  6547. IFS=$as_save_IFS
  6548. test -z "$as_dir" && as_dir=.
  6549. for ac_exec_ext in '' $ac_executable_extensions; do
  6550. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6551. ac_cv_path_DOT="$as_dir/$ac_word$ac_exec_ext"
  6552. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6553. break 2
  6554. fi
  6555. done
  6556. done
  6557. IFS=$as_save_IFS
  6558. test -z "$ac_cv_path_DOT" && ac_cv_path_DOT=":"
  6559. ;;
  6560. esac
  6561. fi
  6562. DOT=$ac_cv_path_DOT
  6563. if test -n "$DOT"; then
  6564. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOT" >&5
  6565. $as_echo "$DOT" >&6; }
  6566. else
  6567. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6568. $as_echo "no" >&6; }
  6569. fi
  6570. # Extract the first word of "wget", so it can be a program name with args.
  6571. set dummy wget; ac_word=$2
  6572. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6573. $as_echo_n "checking for $ac_word... " >&6; }
  6574. if ${ac_cv_path_WGET+:} false; then :
  6575. $as_echo_n "(cached) " >&6
  6576. else
  6577. case $WGET in
  6578. [\\/]* | ?:[\\/]*)
  6579. ac_cv_path_WGET="$WGET" # Let the user override the test with a path.
  6580. ;;
  6581. *)
  6582. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6583. for as_dir in $PATH
  6584. do
  6585. IFS=$as_save_IFS
  6586. test -z "$as_dir" && as_dir=.
  6587. for ac_exec_ext in '' $ac_executable_extensions; do
  6588. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6589. ac_cv_path_WGET="$as_dir/$ac_word$ac_exec_ext"
  6590. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6591. break 2
  6592. fi
  6593. done
  6594. done
  6595. IFS=$as_save_IFS
  6596. test -z "$ac_cv_path_WGET" && ac_cv_path_WGET=":"
  6597. ;;
  6598. esac
  6599. fi
  6600. WGET=$ac_cv_path_WGET
  6601. if test -n "$WGET"; then
  6602. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WGET" >&5
  6603. $as_echo "$WGET" >&6; }
  6604. else
  6605. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6606. $as_echo "no" >&6; }
  6607. fi
  6608. # Extract the first word of "curl", so it can be a program name with args.
  6609. set dummy curl; ac_word=$2
  6610. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6611. $as_echo_n "checking for $ac_word... " >&6; }
  6612. if ${ac_cv_path_CURL+:} false; then :
  6613. $as_echo_n "(cached) " >&6
  6614. else
  6615. case $CURL in
  6616. [\\/]* | ?:[\\/]*)
  6617. ac_cv_path_CURL="$CURL" # Let the user override the test with a path.
  6618. ;;
  6619. *)
  6620. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6621. for as_dir in $PATH
  6622. do
  6623. IFS=$as_save_IFS
  6624. test -z "$as_dir" && as_dir=.
  6625. for ac_exec_ext in '' $ac_executable_extensions; do
  6626. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6627. ac_cv_path_CURL="$as_dir/$ac_word$ac_exec_ext"
  6628. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6629. break 2
  6630. fi
  6631. done
  6632. done
  6633. IFS=$as_save_IFS
  6634. test -z "$ac_cv_path_CURL" && ac_cv_path_CURL=":"
  6635. ;;
  6636. esac
  6637. fi
  6638. CURL=$ac_cv_path_CURL
  6639. if test -n "$CURL"; then
  6640. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CURL" >&5
  6641. $as_echo "$CURL" >&6; }
  6642. else
  6643. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6644. $as_echo "no" >&6; }
  6645. fi
  6646. # Extract the first word of "rubber", so it can be a program name with args.
  6647. set dummy rubber; ac_word=$2
  6648. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6649. $as_echo_n "checking for $ac_word... " >&6; }
  6650. if ${ac_cv_path_RUBBER+:} false; then :
  6651. $as_echo_n "(cached) " >&6
  6652. else
  6653. case $RUBBER in
  6654. [\\/]* | ?:[\\/]*)
  6655. ac_cv_path_RUBBER="$RUBBER" # Let the user override the test with a path.
  6656. ;;
  6657. *)
  6658. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6659. for as_dir in $PATH
  6660. do
  6661. IFS=$as_save_IFS
  6662. test -z "$as_dir" && as_dir=.
  6663. for ac_exec_ext in '' $ac_executable_extensions; do
  6664. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6665. ac_cv_path_RUBBER="$as_dir/$ac_word$ac_exec_ext"
  6666. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6667. break 2
  6668. fi
  6669. done
  6670. done
  6671. IFS=$as_save_IFS
  6672. test -z "$ac_cv_path_RUBBER" && ac_cv_path_RUBBER=":"
  6673. ;;
  6674. esac
  6675. fi
  6676. RUBBER=$ac_cv_path_RUBBER
  6677. if test -n "$RUBBER"; then
  6678. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUBBER" >&5
  6679. $as_echo "$RUBBER" >&6; }
  6680. else
  6681. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6682. $as_echo "no" >&6; }
  6683. fi
  6684. # Extract the first word of "catdvi", so it can be a program name with args.
  6685. set dummy catdvi; ac_word=$2
  6686. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6687. $as_echo_n "checking for $ac_word... " >&6; }
  6688. if ${ac_cv_path_CATDVI+:} false; then :
  6689. $as_echo_n "(cached) " >&6
  6690. else
  6691. case $CATDVI in
  6692. [\\/]* | ?:[\\/]*)
  6693. ac_cv_path_CATDVI="$CATDVI" # Let the user override the test with a path.
  6694. ;;
  6695. *)
  6696. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6697. for as_dir in $PATH
  6698. do
  6699. IFS=$as_save_IFS
  6700. test -z "$as_dir" && as_dir=.
  6701. for ac_exec_ext in '' $ac_executable_extensions; do
  6702. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6703. ac_cv_path_CATDVI="$as_dir/$ac_word$ac_exec_ext"
  6704. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6705. break 2
  6706. fi
  6707. done
  6708. done
  6709. IFS=$as_save_IFS
  6710. test -z "$ac_cv_path_CATDVI" && ac_cv_path_CATDVI=":"
  6711. ;;
  6712. esac
  6713. fi
  6714. CATDVI=$ac_cv_path_CATDVI
  6715. if test -n "$CATDVI"; then
  6716. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CATDVI" >&5
  6717. $as_echo "$CATDVI" >&6; }
  6718. else
  6719. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6720. $as_echo "no" >&6; }
  6721. fi
  6722. # Extract the first word of "kpsewhich", so it can be a program name with args.
  6723. set dummy kpsewhich; ac_word=$2
  6724. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6725. $as_echo_n "checking for $ac_word... " >&6; }
  6726. if ${ac_cv_path_KPATHSEA+:} false; then :
  6727. $as_echo_n "(cached) " >&6
  6728. else
  6729. case $KPATHSEA in
  6730. [\\/]* | ?:[\\/]*)
  6731. ac_cv_path_KPATHSEA="$KPATHSEA" # Let the user override the test with a path.
  6732. ;;
  6733. *)
  6734. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6735. for as_dir in $PATH
  6736. do
  6737. IFS=$as_save_IFS
  6738. test -z "$as_dir" && as_dir=.
  6739. for ac_exec_ext in '' $ac_executable_extensions; do
  6740. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6741. ac_cv_path_KPATHSEA="$as_dir/$ac_word$ac_exec_ext"
  6742. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6743. break 2
  6744. fi
  6745. done
  6746. done
  6747. IFS=$as_save_IFS
  6748. test -z "$ac_cv_path_KPATHSEA" && ac_cv_path_KPATHSEA=":"
  6749. ;;
  6750. esac
  6751. fi
  6752. KPATHSEA=$ac_cv_path_KPATHSEA
  6753. if test -n "$KPATHSEA"; then
  6754. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $KPATHSEA" >&5
  6755. $as_echo "$KPATHSEA" >&6; }
  6756. else
  6757. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6758. $as_echo "no" >&6; }
  6759. fi
  6760. # Extract the first word of "xmllint", so it can be a program name with args.
  6761. set dummy xmllint; ac_word=$2
  6762. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6763. $as_echo_n "checking for $ac_word... " >&6; }
  6764. if ${ac_cv_path_XMLLINT+:} false; then :
  6765. $as_echo_n "(cached) " >&6
  6766. else
  6767. case $XMLLINT in
  6768. [\\/]* | ?:[\\/]*)
  6769. ac_cv_path_XMLLINT="$XMLLINT" # Let the user override the test with a path.
  6770. ;;
  6771. *)
  6772. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6773. for as_dir in $PATH
  6774. do
  6775. IFS=$as_save_IFS
  6776. test -z "$as_dir" && as_dir=.
  6777. for ac_exec_ext in '' $ac_executable_extensions; do
  6778. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6779. ac_cv_path_XMLLINT="$as_dir/$ac_word$ac_exec_ext"
  6780. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6781. break 2
  6782. fi
  6783. done
  6784. done
  6785. IFS=$as_save_IFS
  6786. test -z "$ac_cv_path_XMLLINT" && ac_cv_path_XMLLINT=":"
  6787. ;;
  6788. esac
  6789. fi
  6790. XMLLINT=$ac_cv_path_XMLLINT
  6791. if test -n "$XMLLINT"; then
  6792. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
  6793. $as_echo "$XMLLINT" >&6; }
  6794. else
  6795. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6796. $as_echo "no" >&6; }
  6797. fi
  6798. # Extract the first word of "xmlstarlet", so it can be a program name with args.
  6799. set dummy xmlstarlet; ac_word=$2
  6800. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6801. $as_echo_n "checking for $ac_word... " >&6; }
  6802. if ${ac_cv_path_XMLSTARLET+:} false; then :
  6803. $as_echo_n "(cached) " >&6
  6804. else
  6805. case $XMLSTARLET in
  6806. [\\/]* | ?:[\\/]*)
  6807. ac_cv_path_XMLSTARLET="$XMLSTARLET" # Let the user override the test with a path.
  6808. ;;
  6809. *)
  6810. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6811. for as_dir in $PATH
  6812. do
  6813. IFS=$as_save_IFS
  6814. test -z "$as_dir" && as_dir=.
  6815. for ac_exec_ext in '' $ac_executable_extensions; do
  6816. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6817. ac_cv_path_XMLSTARLET="$as_dir/$ac_word$ac_exec_ext"
  6818. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6819. break 2
  6820. fi
  6821. done
  6822. done
  6823. IFS=$as_save_IFS
  6824. test -z "$ac_cv_path_XMLSTARLET" && ac_cv_path_XMLSTARLET=":"
  6825. ;;
  6826. esac
  6827. fi
  6828. XMLSTARLET=$ac_cv_path_XMLSTARLET
  6829. if test -n "$XMLSTARLET"; then
  6830. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLSTARLET" >&5
  6831. $as_echo "$XMLSTARLET" >&6; }
  6832. else
  6833. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6834. $as_echo "no" >&6; }
  6835. fi
  6836. # Extract the first word of "git", so it can be a program name with args.
  6837. set dummy git; ac_word=$2
  6838. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6839. $as_echo_n "checking for $ac_word... " >&6; }
  6840. if ${ac_cv_path_GIT+:} false; then :
  6841. $as_echo_n "(cached) " >&6
  6842. else
  6843. case $GIT in
  6844. [\\/]* | ?:[\\/]*)
  6845. ac_cv_path_GIT="$GIT" # Let the user override the test with a path.
  6846. ;;
  6847. *)
  6848. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6849. for as_dir in $PATH
  6850. do
  6851. IFS=$as_save_IFS
  6852. test -z "$as_dir" && as_dir=.
  6853. for ac_exec_ext in '' $ac_executable_extensions; do
  6854. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6855. ac_cv_path_GIT="$as_dir/$ac_word$ac_exec_ext"
  6856. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6857. break 2
  6858. fi
  6859. done
  6860. done
  6861. IFS=$as_save_IFS
  6862. test -z "$ac_cv_path_GIT" && ac_cv_path_GIT=":"
  6863. ;;
  6864. esac
  6865. fi
  6866. GIT=$ac_cv_path_GIT
  6867. if test -n "$GIT"; then
  6868. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GIT" >&5
  6869. $as_echo "$GIT" >&6; }
  6870. else
  6871. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6872. $as_echo "no" >&6; }
  6873. fi
  6874. if test "${WGET}" != ":" ; then
  6875. DOWNLOAD=${WGET}
  6876. else if test "${CURL}" != ":" ; then
  6877. DOWNLOAD="${CURL} -O --progress-bar -w \"%{url_effective}\n\""
  6878. else
  6879. # Extract the first word of "fetch", so it can be a program name with args.
  6880. set dummy fetch; ac_word=$2
  6881. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6882. $as_echo_n "checking for $ac_word... " >&6; }
  6883. if ${ac_cv_path_FETCH+:} false; then :
  6884. $as_echo_n "(cached) " >&6
  6885. else
  6886. case $FETCH in
  6887. [\\/]* | ?:[\\/]*)
  6888. ac_cv_path_FETCH="$FETCH" # Let the user override the test with a path.
  6889. ;;
  6890. *)
  6891. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6892. for as_dir in $PATH
  6893. do
  6894. IFS=$as_save_IFS
  6895. test -z "$as_dir" && as_dir=.
  6896. for ac_exec_ext in '' $ac_executable_extensions; do
  6897. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6898. ac_cv_path_FETCH="$as_dir/$ac_word$ac_exec_ext"
  6899. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6900. break 2
  6901. fi
  6902. done
  6903. done
  6904. IFS=$as_save_IFS
  6905. test -z "$ac_cv_path_FETCH" && ac_cv_path_FETCH=":"
  6906. ;;
  6907. esac
  6908. fi
  6909. FETCH=$ac_cv_path_FETCH
  6910. if test -n "$FETCH"; then
  6911. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FETCH" >&5
  6912. $as_echo "$FETCH" >&6; }
  6913. else
  6914. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6915. $as_echo "no" >&6; }
  6916. fi
  6917. DOWNLOAD=${FETCH}
  6918. fi
  6919. fi
  6920. # Extract the first word of "ldconfig", so it can be a program name with args.
  6921. set dummy ldconfig; ac_word=$2
  6922. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6923. $as_echo_n "checking for $ac_word... " >&6; }
  6924. if ${ac_cv_path_LDCONFIG+:} false; then :
  6925. $as_echo_n "(cached) " >&6
  6926. else
  6927. case $LDCONFIG in
  6928. [\\/]* | ?:[\\/]*)
  6929. ac_cv_path_LDCONFIG="$LDCONFIG" # Let the user override the test with a path.
  6930. ;;
  6931. *)
  6932. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6933. for as_dir in $PATH
  6934. do
  6935. IFS=$as_save_IFS
  6936. test -z "$as_dir" && as_dir=.
  6937. for ac_exec_ext in '' $ac_executable_extensions; do
  6938. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6939. ac_cv_path_LDCONFIG="$as_dir/$ac_word$ac_exec_ext"
  6940. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6941. break 2
  6942. fi
  6943. done
  6944. done
  6945. IFS=$as_save_IFS
  6946. test -z "$ac_cv_path_LDCONFIG" && ac_cv_path_LDCONFIG=":"
  6947. ;;
  6948. esac
  6949. fi
  6950. LDCONFIG=$ac_cv_path_LDCONFIG
  6951. if test -n "$LDCONFIG"; then
  6952. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDCONFIG" >&5
  6953. $as_echo "$LDCONFIG" >&6; }
  6954. else
  6955. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6956. $as_echo "no" >&6; }
  6957. fi
  6958. # Extract the first word of "sha1sum", so it can be a program name with args.
  6959. set dummy sha1sum; ac_word=$2
  6960. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6961. $as_echo_n "checking for $ac_word... " >&6; }
  6962. if ${ac_cv_path_SHA1SUM+:} false; then :
  6963. $as_echo_n "(cached) " >&6
  6964. else
  6965. case $SHA1SUM in
  6966. [\\/]* | ?:[\\/]*)
  6967. ac_cv_path_SHA1SUM="$SHA1SUM" # Let the user override the test with a path.
  6968. ;;
  6969. *)
  6970. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  6971. for as_dir in $PATH
  6972. do
  6973. IFS=$as_save_IFS
  6974. test -z "$as_dir" && as_dir=.
  6975. for ac_exec_ext in '' $ac_executable_extensions; do
  6976. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  6977. ac_cv_path_SHA1SUM="$as_dir/$ac_word$ac_exec_ext"
  6978. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  6979. break 2
  6980. fi
  6981. done
  6982. done
  6983. IFS=$as_save_IFS
  6984. test -z "$ac_cv_path_SHA1SUM" && ac_cv_path_SHA1SUM="$ac_aux_dir/build_tools/sha1sum-sh"
  6985. ;;
  6986. esac
  6987. fi
  6988. SHA1SUM=$ac_cv_path_SHA1SUM
  6989. if test -n "$SHA1SUM"; then
  6990. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHA1SUM" >&5
  6991. $as_echo "$SHA1SUM" >&6; }
  6992. else
  6993. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  6994. $as_echo "no" >&6; }
  6995. fi
  6996. # Extract the first word of "openssl", so it can be a program name with args.
  6997. set dummy openssl; ac_word=$2
  6998. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  6999. $as_echo_n "checking for $ac_word... " >&6; }
  7000. if ${ac_cv_path_OPENSSL+:} false; then :
  7001. $as_echo_n "(cached) " >&6
  7002. else
  7003. case $OPENSSL in
  7004. [\\/]* | ?:[\\/]*)
  7005. ac_cv_path_OPENSSL="$OPENSSL" # Let the user override the test with a path.
  7006. ;;
  7007. *)
  7008. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7009. for as_dir in $PATH
  7010. do
  7011. IFS=$as_save_IFS
  7012. test -z "$as_dir" && as_dir=.
  7013. for ac_exec_ext in '' $ac_executable_extensions; do
  7014. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7015. ac_cv_path_OPENSSL="$as_dir/$ac_word$ac_exec_ext"
  7016. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7017. break 2
  7018. fi
  7019. done
  7020. done
  7021. IFS=$as_save_IFS
  7022. test -z "$ac_cv_path_OPENSSL" && ac_cv_path_OPENSSL=":"
  7023. ;;
  7024. esac
  7025. fi
  7026. OPENSSL=$ac_cv_path_OPENSSL
  7027. if test -n "$OPENSSL"; then
  7028. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENSSL" >&5
  7029. $as_echo "$OPENSSL" >&6; }
  7030. else
  7031. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7032. $as_echo "no" >&6; }
  7033. fi
  7034. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bison that supports parse-param" >&5
  7035. $as_echo_n "checking for bison that supports parse-param... " >&6; }
  7036. if ${ac_cv_path_BISON2+:} false; then :
  7037. $as_echo_n "(cached) " >&6
  7038. else
  7039. if test "x$BISON" != "x:" ; then
  7040. # Create a temporary directory $tmp in $TMPDIR (default /tmp).
  7041. # Use mktemp if possible; otherwise fall back on mkdir,
  7042. # with $RANDOM to make collisions less likely.
  7043. : ${TMPDIR=/tmp}
  7044. {
  7045. tmp=`
  7046. (umask 077 && mktemp -d "$TMPDIR/fooXXXXXX") 2>/dev/null
  7047. ` &&
  7048. test -n "$tmp" && test -d "$tmp"
  7049. } || {
  7050. tmp=$TMPDIR/foo$$-$RANDOM
  7051. (umask 077 && mkdir "$tmp")
  7052. } || exit $?
  7053. cat >$tmp/test.y <<__EOL__
  7054. %parse-param {struct parse_io *parseio}
  7055. %%
  7056. file : { \$\$ = parseio->pval = 1; }
  7057. ;
  7058. %%
  7059. __EOL__
  7060. ${BISON} -o ${tmp}/test.tab.c ${tmp}/test.y >/dev/null 2>&1
  7061. if test -e "${tmp}/test.tab.c"; then
  7062. ac_cv_path_BISON2=${BISON}
  7063. fi
  7064. rm -rf ${tmp}
  7065. fi
  7066. fi
  7067. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_BISON2" >&5
  7068. $as_echo "$ac_cv_path_BISON2" >&6; }
  7069. if test "x${ac_cv_path_BISON2}" = "x" ; then
  7070. BISON=:
  7071. PBX_BISON=0
  7072. else
  7073. PBX_BISON=1
  7074. fi
  7075. if test "x${FLEX}" = "x:" ; then
  7076. PBX_FLEX=0
  7077. else
  7078. PBX_FLEX=1
  7079. fi
  7080. if test -n "$ac_tool_prefix"; then
  7081. # Extract the first word of "${ac_tool_prefix}soxmix", so it can be a program name with args.
  7082. set dummy ${ac_tool_prefix}soxmix; ac_word=$2
  7083. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7084. $as_echo_n "checking for $ac_word... " >&6; }
  7085. if ${ac_cv_prog_SOXMIX+:} false; then :
  7086. $as_echo_n "(cached) " >&6
  7087. else
  7088. if test -n "$SOXMIX"; then
  7089. ac_cv_prog_SOXMIX="$SOXMIX" # Let the user override the test.
  7090. else
  7091. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7092. for as_dir in $PATH
  7093. do
  7094. IFS=$as_save_IFS
  7095. test -z "$as_dir" && as_dir=.
  7096. for ac_exec_ext in '' $ac_executable_extensions; do
  7097. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7098. ac_cv_prog_SOXMIX="${ac_tool_prefix}soxmix"
  7099. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7100. break 2
  7101. fi
  7102. done
  7103. done
  7104. IFS=$as_save_IFS
  7105. fi
  7106. fi
  7107. SOXMIX=$ac_cv_prog_SOXMIX
  7108. if test -n "$SOXMIX"; then
  7109. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SOXMIX" >&5
  7110. $as_echo "$SOXMIX" >&6; }
  7111. else
  7112. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7113. $as_echo "no" >&6; }
  7114. fi
  7115. fi
  7116. if test -z "$ac_cv_prog_SOXMIX"; then
  7117. ac_ct_SOXMIX=$SOXMIX
  7118. # Extract the first word of "soxmix", so it can be a program name with args.
  7119. set dummy soxmix; ac_word=$2
  7120. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7121. $as_echo_n "checking for $ac_word... " >&6; }
  7122. if ${ac_cv_prog_ac_ct_SOXMIX+:} false; then :
  7123. $as_echo_n "(cached) " >&6
  7124. else
  7125. if test -n "$ac_ct_SOXMIX"; then
  7126. ac_cv_prog_ac_ct_SOXMIX="$ac_ct_SOXMIX" # Let the user override the test.
  7127. else
  7128. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7129. for as_dir in $PATH
  7130. do
  7131. IFS=$as_save_IFS
  7132. test -z "$as_dir" && as_dir=.
  7133. for ac_exec_ext in '' $ac_executable_extensions; do
  7134. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7135. ac_cv_prog_ac_ct_SOXMIX="soxmix"
  7136. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7137. break 2
  7138. fi
  7139. done
  7140. done
  7141. IFS=$as_save_IFS
  7142. fi
  7143. fi
  7144. ac_ct_SOXMIX=$ac_cv_prog_ac_ct_SOXMIX
  7145. if test -n "$ac_ct_SOXMIX"; then
  7146. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_SOXMIX" >&5
  7147. $as_echo "$ac_ct_SOXMIX" >&6; }
  7148. else
  7149. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7150. $as_echo "no" >&6; }
  7151. fi
  7152. if test "x$ac_ct_SOXMIX" = x; then
  7153. SOXMIX=":"
  7154. else
  7155. case $cross_compiling:$ac_tool_warned in
  7156. yes:)
  7157. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  7158. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  7159. ac_tool_warned=yes ;;
  7160. esac
  7161. SOXMIX=$ac_ct_SOXMIX
  7162. fi
  7163. else
  7164. SOXMIX="$ac_cv_prog_SOXMIX"
  7165. fi
  7166. if test "${SOXMIX}" != ":" ; then
  7167. $as_echo "#define HAVE_SOXMIX 1" >>confdefs.h
  7168. fi
  7169. for ac_prog in md5 md5sum gmd5sum digest
  7170. do
  7171. # Extract the first word of "$ac_prog", so it can be a program name with args.
  7172. set dummy $ac_prog; ac_word=$2
  7173. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7174. $as_echo_n "checking for $ac_word... " >&6; }
  7175. if ${ac_cv_prog_MD5+:} false; then :
  7176. $as_echo_n "(cached) " >&6
  7177. else
  7178. if test -n "$MD5"; then
  7179. ac_cv_prog_MD5="$MD5" # Let the user override the test.
  7180. else
  7181. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7182. for as_dir in $PATH
  7183. do
  7184. IFS=$as_save_IFS
  7185. test -z "$as_dir" && as_dir=.
  7186. for ac_exec_ext in '' $ac_executable_extensions; do
  7187. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7188. ac_cv_prog_MD5="$ac_prog"
  7189. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7190. break 2
  7191. fi
  7192. done
  7193. done
  7194. IFS=$as_save_IFS
  7195. fi
  7196. fi
  7197. MD5=$ac_cv_prog_MD5
  7198. if test -n "$MD5"; then
  7199. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MD5" >&5
  7200. $as_echo "$MD5" >&6; }
  7201. else
  7202. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7203. $as_echo "no" >&6; }
  7204. fi
  7205. test -n "$MD5" && break
  7206. done
  7207. if test "${MD5}" = "digest" ; then
  7208. MD5="${MD5} -a md5"
  7209. fi
  7210. ac_ext=c
  7211. ac_cpp='$CPP $CPPFLAGS'
  7212. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  7213. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  7214. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  7215. acx_pthread_ok=no
  7216. # We used to check for pthread.h first, but this fails if pthread.h
  7217. # requires special compiler flags (e.g. on True64 or Sequent).
  7218. # It gets checked for in the link test anyway.
  7219. # First of all, check if the user has set any of the PTHREAD_LIBS,
  7220. # etcetera environment variables, and if threads linking works using
  7221. # them:
  7222. if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
  7223. save_CFLAGS="$CFLAGS"
  7224. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  7225. save_LIBS="$LIBS"
  7226. LIBS="$PTHREAD_LIBS $LIBS"
  7227. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
  7228. $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
  7229. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7230. /* end confdefs.h. */
  7231. /* Override any GCC internal prototype to avoid an error.
  7232. Use char because int might match the return type of a GCC
  7233. builtin and then its argument prototype would still apply. */
  7234. #ifdef __cplusplus
  7235. extern "C"
  7236. #endif
  7237. char pthread_join ();
  7238. int
  7239. main ()
  7240. {
  7241. return pthread_join ();
  7242. ;
  7243. return 0;
  7244. }
  7245. _ACEOF
  7246. if ac_fn_c_try_link "$LINENO"; then :
  7247. acx_pthread_ok=yes
  7248. fi
  7249. rm -f core conftest.err conftest.$ac_objext \
  7250. conftest$ac_exeext conftest.$ac_ext
  7251. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5
  7252. $as_echo "$acx_pthread_ok" >&6; }
  7253. if test x"$acx_pthread_ok" = xno; then
  7254. PTHREAD_LIBS=""
  7255. PTHREAD_CFLAGS=""
  7256. fi
  7257. LIBS="$save_LIBS"
  7258. CFLAGS="$save_CFLAGS"
  7259. fi
  7260. # We must check for the threads library under a number of different
  7261. # names; the ordering is very important because some systems
  7262. # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
  7263. # libraries is broken (non-POSIX).
  7264. # Create a list of thread flags to try. Items starting with a "-" are
  7265. # C compiler flags, and other items are library names, except for "none"
  7266. # which indicates that we try without any flags at all, and "pthread-config"
  7267. # which is a program returning the flags for the Pth emulation library.
  7268. acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
  7269. # The ordering *is* (sometimes) important. Some notes on the
  7270. # individual items follow:
  7271. # pthreads: AIX (must check this before -lpthread)
  7272. # none: in case threads are in libc; should be tried before -Kthread and
  7273. # other compiler flags to prevent continual compiler warnings
  7274. # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
  7275. # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
  7276. # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
  7277. # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
  7278. # -pthreads: Solaris/gcc
  7279. # -mthreads: Mingw32/gcc, Lynx/gcc
  7280. # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
  7281. # doesn't hurt to check since this sometimes defines pthreads too;
  7282. # also defines -D_REENTRANT)
  7283. # ... -mt is also the pthreads flag for HP/aCC
  7284. # pthread: Linux, etcetera
  7285. # --thread-safe: KAI C++
  7286. # pthread-config: use pthread-config program (for GNU Pth library)
  7287. case "${host_cpu}-${host_os}" in
  7288. *solaris*)
  7289. # On Solaris (at least, for some versions), libc contains stubbed
  7290. # (non-functional) versions of the pthreads routines, so link-based
  7291. # tests will erroneously succeed. (We need to link with -pthreads/-mt/
  7292. # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather
  7293. # a function called by this macro, so we could check for that, but
  7294. # who knows whether they'll stub that too in a future libc.) So,
  7295. # we'll just look for -pthreads and -lpthread first:
  7296. acx_pthread_flags="-pthreads pthread -mt -pthread $acx_pthread_flags"
  7297. ;;
  7298. esac
  7299. if test x"$acx_pthread_ok" = xno; then
  7300. for flag in $acx_pthread_flags; do
  7301. case $flag in
  7302. none)
  7303. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
  7304. $as_echo_n "checking whether pthreads work without any flags... " >&6; }
  7305. ;;
  7306. -*)
  7307. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $flag" >&5
  7308. $as_echo_n "checking whether pthreads work with $flag... " >&6; }
  7309. PTHREAD_CFLAGS="$flag"
  7310. ;;
  7311. pthread-config)
  7312. # Extract the first word of "pthread-config", so it can be a program name with args.
  7313. set dummy pthread-config; ac_word=$2
  7314. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7315. $as_echo_n "checking for $ac_word... " >&6; }
  7316. if ${ac_cv_prog_acx_pthread_config+:} false; then :
  7317. $as_echo_n "(cached) " >&6
  7318. else
  7319. if test -n "$acx_pthread_config"; then
  7320. ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
  7321. else
  7322. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7323. for as_dir in $PATH
  7324. do
  7325. IFS=$as_save_IFS
  7326. test -z "$as_dir" && as_dir=.
  7327. for ac_exec_ext in '' $ac_executable_extensions; do
  7328. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7329. ac_cv_prog_acx_pthread_config="yes"
  7330. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7331. break 2
  7332. fi
  7333. done
  7334. done
  7335. IFS=$as_save_IFS
  7336. test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
  7337. fi
  7338. fi
  7339. acx_pthread_config=$ac_cv_prog_acx_pthread_config
  7340. if test -n "$acx_pthread_config"; then
  7341. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_config" >&5
  7342. $as_echo "$acx_pthread_config" >&6; }
  7343. else
  7344. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7345. $as_echo "no" >&6; }
  7346. fi
  7347. if test x"$acx_pthread_config" = xno; then continue; fi
  7348. PTHREAD_CFLAGS="`pthread-config --cflags`"
  7349. PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
  7350. ;;
  7351. *)
  7352. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$flag" >&5
  7353. $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
  7354. PTHREAD_LIBS="-l$flag"
  7355. ;;
  7356. esac
  7357. save_LIBS="$LIBS"
  7358. save_CFLAGS="$CFLAGS"
  7359. LIBS="$PTHREAD_LIBS $LIBS"
  7360. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  7361. # Check for various functions. We must include pthread.h,
  7362. # since some functions may be macros. (On the Sequent, we
  7363. # need a special flag -Kthread to make this header compile.)
  7364. # We check for pthread_join because it is in -lpthread on IRIX
  7365. # while pthread_create is in libc. We check for pthread_attr_init
  7366. # due to DEC craziness with -lpthreads. We check for
  7367. # pthread_cleanup_push because it is one of the few pthread
  7368. # functions on Solaris that doesn't have a non-functional libc stub.
  7369. # We try pthread_create on general principles.
  7370. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7371. /* end confdefs.h. */
  7372. #include <pthread.h>
  7373. int
  7374. main ()
  7375. {
  7376. pthread_t th; pthread_join(th, 0);
  7377. pthread_attr_init(0); pthread_cleanup_push(0, 0);
  7378. pthread_create(0,0,0,0); pthread_cleanup_pop(0);
  7379. ;
  7380. return 0;
  7381. }
  7382. _ACEOF
  7383. if ac_fn_c_try_link "$LINENO"; then :
  7384. acx_pthread_ok=yes
  7385. fi
  7386. rm -f core conftest.err conftest.$ac_objext \
  7387. conftest$ac_exeext conftest.$ac_ext
  7388. LIBS="$save_LIBS"
  7389. CFLAGS="$save_CFLAGS"
  7390. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_pthread_ok" >&5
  7391. $as_echo "$acx_pthread_ok" >&6; }
  7392. if test "x$acx_pthread_ok" = xyes; then
  7393. break;
  7394. fi
  7395. PTHREAD_LIBS=""
  7396. PTHREAD_CFLAGS=""
  7397. done
  7398. fi
  7399. # Various other checks:
  7400. if test "x$acx_pthread_ok" = xyes; then
  7401. save_LIBS="$LIBS"
  7402. LIBS="$PTHREAD_LIBS $LIBS"
  7403. save_CFLAGS="$CFLAGS"
  7404. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  7405. # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
  7406. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
  7407. $as_echo_n "checking for joinable pthread attribute... " >&6; }
  7408. attr_name=unknown
  7409. for attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
  7410. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  7411. /* end confdefs.h. */
  7412. #include <pthread.h>
  7413. int
  7414. main ()
  7415. {
  7416. int attr=$attr; return attr;
  7417. ;
  7418. return 0;
  7419. }
  7420. _ACEOF
  7421. if ac_fn_c_try_link "$LINENO"; then :
  7422. attr_name=$attr; break
  7423. fi
  7424. rm -f core conftest.err conftest.$ac_objext \
  7425. conftest$ac_exeext conftest.$ac_ext
  7426. done
  7427. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $attr_name" >&5
  7428. $as_echo "$attr_name" >&6; }
  7429. if test "$attr_name" != PTHREAD_CREATE_JOINABLE; then
  7430. cat >>confdefs.h <<_ACEOF
  7431. #define PTHREAD_CREATE_JOINABLE $attr_name
  7432. _ACEOF
  7433. fi
  7434. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if more special flags are required for pthreads" >&5
  7435. $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
  7436. flag=no
  7437. case "${host_cpu}-${host_os}" in
  7438. *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
  7439. *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
  7440. esac
  7441. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${flag}" >&5
  7442. $as_echo "${flag}" >&6; }
  7443. if test "x$flag" != xno; then
  7444. PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
  7445. fi
  7446. LIBS="$save_LIBS"
  7447. CFLAGS="$save_CFLAGS"
  7448. # More AIX lossage: must compile with xlc_r or cc_r
  7449. if test x"$GCC" != xyes; then
  7450. for ac_prog in xlc_r cc_r
  7451. do
  7452. # Extract the first word of "$ac_prog", so it can be a program name with args.
  7453. set dummy $ac_prog; ac_word=$2
  7454. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  7455. $as_echo_n "checking for $ac_word... " >&6; }
  7456. if ${ac_cv_prog_PTHREAD_CC+:} false; then :
  7457. $as_echo_n "(cached) " >&6
  7458. else
  7459. if test -n "$PTHREAD_CC"; then
  7460. ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
  7461. else
  7462. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  7463. for as_dir in $PATH
  7464. do
  7465. IFS=$as_save_IFS
  7466. test -z "$as_dir" && as_dir=.
  7467. for ac_exec_ext in '' $ac_executable_extensions; do
  7468. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  7469. ac_cv_prog_PTHREAD_CC="$ac_prog"
  7470. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  7471. break 2
  7472. fi
  7473. done
  7474. done
  7475. IFS=$as_save_IFS
  7476. fi
  7477. fi
  7478. PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
  7479. if test -n "$PTHREAD_CC"; then
  7480. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
  7481. $as_echo "$PTHREAD_CC" >&6; }
  7482. else
  7483. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  7484. $as_echo "no" >&6; }
  7485. fi
  7486. test -n "$PTHREAD_CC" && break
  7487. done
  7488. test -n "$PTHREAD_CC" || PTHREAD_CC="${CC}"
  7489. else
  7490. PTHREAD_CC=$CC
  7491. fi
  7492. else
  7493. PTHREAD_CC="$CC"
  7494. fi
  7495. # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
  7496. if test x"$acx_pthread_ok" = xyes; then
  7497. $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
  7498. :
  7499. else
  7500. acx_pthread_ok=no
  7501. fi
  7502. ac_ext=c
  7503. ac_cpp='$CPP $CPPFLAGS'
  7504. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  7505. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  7506. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  7507. ac_ext=c
  7508. ac_cpp='$CPP $CPPFLAGS'
  7509. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  7510. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  7511. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  7512. # Check whether --enable-dev-mode was given.
  7513. if test "${enable_dev_mode+set}" = set; then :
  7514. enableval=$enable_dev_mode; case "${enableval}" in
  7515. y|ye|yes) AST_DEVMODE=yes ;;
  7516. n|no) AST_DEVMODE=no ;;
  7517. noisy)
  7518. AST_DEVMODE=yes
  7519. NOISY_BUILD=yes
  7520. ;;
  7521. strict)
  7522. AST_DEVMODE=yes
  7523. AST_DEVMODE_STRICT=yes
  7524. ;;
  7525. *) as_fn_error $? "bad value ${enableval} for --enable-dev-mode" "$LINENO" 5 ;;
  7526. esac
  7527. fi
  7528. AST_CODE_COVERAGE=no
  7529. # Check whether --enable-coverage was given.
  7530. if test "${enable_coverage+set}" = set; then :
  7531. enableval=$enable_coverage; case "${enableval}" in
  7532. y|ye|yes) AST_CODE_COVERAGE=yes ;;
  7533. n|no) AST_CODE_COVERAGE=no ;;
  7534. *) as_fn_error $? "bad value ${enableval} for --enable-coverage" "$LINENO" 5 ;;
  7535. esac
  7536. fi
  7537. # AST_EXT_LIB_SETUP is used to tell configure to handle variables for
  7538. # various packages.
  7539. # $1 is the prefix for the variables in makeopts and autoconfig.h
  7540. # $2 is the short comment, $4 is the long comment
  7541. # $3 is the name used in --with- or --without- flags for configure.
  7542. #
  7543. # Package option names should be in alphabetical order
  7544. # by the --with option name (the third field),
  7545. # to make things easier for the users.
  7546. ALSA_DESCRIP="Advanced Linux Sound Architecture"
  7547. ALSA_OPTION="asound"
  7548. PBX_ALSA=0
  7549. # Check whether --with-asound was given.
  7550. if test "${with_asound+set}" = set; then :
  7551. withval=$with_asound;
  7552. case ${withval} in
  7553. n|no)
  7554. USE_ALSA=no
  7555. # -1 is a magic value used by menuselect to know that the package
  7556. # was disabled, other than 'not found'
  7557. PBX_ALSA=-1
  7558. ;;
  7559. y|ye|yes)
  7560. ac_mandatory_list="${ac_mandatory_list} ALSA"
  7561. ;;
  7562. *)
  7563. ALSA_DIR="${withval}"
  7564. ac_mandatory_list="${ac_mandatory_list} ALSA"
  7565. ;;
  7566. esac
  7567. fi
  7568. BFD_DESCRIP="Debug symbol decoding"
  7569. BFD_OPTION="bfd"
  7570. PBX_BFD=0
  7571. # Check whether --with-bfd was given.
  7572. if test "${with_bfd+set}" = set; then :
  7573. withval=$with_bfd;
  7574. case ${withval} in
  7575. n|no)
  7576. USE_BFD=no
  7577. # -1 is a magic value used by menuselect to know that the package
  7578. # was disabled, other than 'not found'
  7579. PBX_BFD=-1
  7580. ;;
  7581. y|ye|yes)
  7582. ac_mandatory_list="${ac_mandatory_list} BFD"
  7583. ;;
  7584. *)
  7585. BFD_DIR="${withval}"
  7586. ac_mandatory_list="${ac_mandatory_list} BFD"
  7587. ;;
  7588. esac
  7589. fi
  7590. # BKTR is used for backtrace support on platforms that do not
  7591. # have it natively.
  7592. BKTR_DESCRIP="Stack Backtrace"
  7593. BKTR_OPTION="execinfo"
  7594. PBX_BKTR=0
  7595. # Check whether --with-execinfo was given.
  7596. if test "${with_execinfo+set}" = set; then :
  7597. withval=$with_execinfo;
  7598. case ${withval} in
  7599. n|no)
  7600. USE_BKTR=no
  7601. # -1 is a magic value used by menuselect to know that the package
  7602. # was disabled, other than 'not found'
  7603. PBX_BKTR=-1
  7604. ;;
  7605. y|ye|yes)
  7606. ac_mandatory_list="${ac_mandatory_list} BKTR"
  7607. ;;
  7608. *)
  7609. BKTR_DIR="${withval}"
  7610. ac_mandatory_list="${ac_mandatory_list} BKTR"
  7611. ;;
  7612. esac
  7613. fi
  7614. BLUETOOTH_DESCRIP="Bluetooth"
  7615. BLUETOOTH_OPTION="bluetooth"
  7616. PBX_BLUETOOTH=0
  7617. # Check whether --with-bluetooth was given.
  7618. if test "${with_bluetooth+set}" = set; then :
  7619. withval=$with_bluetooth;
  7620. case ${withval} in
  7621. n|no)
  7622. USE_BLUETOOTH=no
  7623. # -1 is a magic value used by menuselect to know that the package
  7624. # was disabled, other than 'not found'
  7625. PBX_BLUETOOTH=-1
  7626. ;;
  7627. y|ye|yes)
  7628. ac_mandatory_list="${ac_mandatory_list} BLUETOOTH"
  7629. ;;
  7630. *)
  7631. BLUETOOTH_DIR="${withval}"
  7632. ac_mandatory_list="${ac_mandatory_list} BLUETOOTH"
  7633. ;;
  7634. esac
  7635. fi
  7636. CAP_DESCRIP="POSIX 1.e capabilities"
  7637. CAP_OPTION="cap"
  7638. PBX_CAP=0
  7639. # Check whether --with-cap was given.
  7640. if test "${with_cap+set}" = set; then :
  7641. withval=$with_cap;
  7642. case ${withval} in
  7643. n|no)
  7644. USE_CAP=no
  7645. # -1 is a magic value used by menuselect to know that the package
  7646. # was disabled, other than 'not found'
  7647. PBX_CAP=-1
  7648. ;;
  7649. y|ye|yes)
  7650. ac_mandatory_list="${ac_mandatory_list} CAP"
  7651. ;;
  7652. *)
  7653. CAP_DIR="${withval}"
  7654. ac_mandatory_list="${ac_mandatory_list} CAP"
  7655. ;;
  7656. esac
  7657. fi
  7658. COROSYNC_DESCRIP="Corosync"
  7659. COROSYNC_OPTION="cpg"
  7660. PBX_COROSYNC=0
  7661. # Check whether --with-cpg was given.
  7662. if test "${with_cpg+set}" = set; then :
  7663. withval=$with_cpg;
  7664. case ${withval} in
  7665. n|no)
  7666. USE_COROSYNC=no
  7667. # -1 is a magic value used by menuselect to know that the package
  7668. # was disabled, other than 'not found'
  7669. PBX_COROSYNC=-1
  7670. ;;
  7671. y|ye|yes)
  7672. ac_mandatory_list="${ac_mandatory_list} COROSYNC"
  7673. ;;
  7674. *)
  7675. COROSYNC_DIR="${withval}"
  7676. ac_mandatory_list="${ac_mandatory_list} COROSYNC"
  7677. ;;
  7678. esac
  7679. fi
  7680. COROSYNC_CFG_STATE_TRACK_DESCRIP="A callback only in corosync 1.x"
  7681. COROSYNC_CFG_STATE_TRACK_OPTION=cfg
  7682. COROSYNC_CFG_STATE_TRACK_DIR=${COROSYNC_DIR}
  7683. PBX_COROSYNC_CFG_STATE_TRACK=0
  7684. CURSES_DESCRIP="curses"
  7685. CURSES_OPTION="curses"
  7686. PBX_CURSES=0
  7687. # Check whether --with-curses was given.
  7688. if test "${with_curses+set}" = set; then :
  7689. withval=$with_curses;
  7690. case ${withval} in
  7691. n|no)
  7692. USE_CURSES=no
  7693. # -1 is a magic value used by menuselect to know that the package
  7694. # was disabled, other than 'not found'
  7695. PBX_CURSES=-1
  7696. ;;
  7697. y|ye|yes)
  7698. ac_mandatory_list="${ac_mandatory_list} CURSES"
  7699. ;;
  7700. *)
  7701. CURSES_DIR="${withval}"
  7702. ac_mandatory_list="${ac_mandatory_list} CURSES"
  7703. ;;
  7704. esac
  7705. fi
  7706. CRYPT_DESCRIP="password and data encryption"
  7707. CRYPT_OPTION="crypt"
  7708. PBX_CRYPT=0
  7709. # Check whether --with-crypt was given.
  7710. if test "${with_crypt+set}" = set; then :
  7711. withval=$with_crypt;
  7712. case ${withval} in
  7713. n|no)
  7714. USE_CRYPT=no
  7715. # -1 is a magic value used by menuselect to know that the package
  7716. # was disabled, other than 'not found'
  7717. PBX_CRYPT=-1
  7718. ;;
  7719. y|ye|yes)
  7720. ac_mandatory_list="${ac_mandatory_list} CRYPT"
  7721. ;;
  7722. *)
  7723. CRYPT_DIR="${withval}"
  7724. ac_mandatory_list="${ac_mandatory_list} CRYPT"
  7725. ;;
  7726. esac
  7727. fi
  7728. CRYPTO_DESCRIP="OpenSSL Cryptography"
  7729. CRYPTO_OPTION="crypto"
  7730. PBX_CRYPTO=0
  7731. # Check whether --with-crypto was given.
  7732. if test "${with_crypto+set}" = set; then :
  7733. withval=$with_crypto;
  7734. case ${withval} in
  7735. n|no)
  7736. USE_CRYPTO=no
  7737. # -1 is a magic value used by menuselect to know that the package
  7738. # was disabled, other than 'not found'
  7739. PBX_CRYPTO=-1
  7740. ;;
  7741. y|ye|yes)
  7742. ac_mandatory_list="${ac_mandatory_list} CRYPTO"
  7743. ;;
  7744. *)
  7745. CRYPTO_DIR="${withval}"
  7746. ac_mandatory_list="${ac_mandatory_list} CRYPTO"
  7747. ;;
  7748. esac
  7749. fi
  7750. OPENSSL_SRTP_DESCRIP="OpenSSL SRTP Extension Support"
  7751. OPENSSL_SRTP_OPTION=crypto
  7752. OPENSSL_SRTP_DIR=${CRYPTO_DIR}
  7753. PBX_OPENSSL_SRTP=0
  7754. OPENSSL_EC_DESCRIP="OpenSSL Elliptic Curve Support"
  7755. OPENSSL_EC_OPTION=crypto
  7756. OPENSSL_EC_DIR=${CRYPTO_DIR}
  7757. PBX_OPENSSL_EC=0
  7758. DAHDI_DESCRIP="DAHDI"
  7759. DAHDI_OPTION="dahdi"
  7760. PBX_DAHDI=0
  7761. # Check whether --with-dahdi was given.
  7762. if test "${with_dahdi+set}" = set; then :
  7763. withval=$with_dahdi;
  7764. case ${withval} in
  7765. n|no)
  7766. USE_DAHDI=no
  7767. # -1 is a magic value used by menuselect to know that the package
  7768. # was disabled, other than 'not found'
  7769. PBX_DAHDI=-1
  7770. ;;
  7771. y|ye|yes)
  7772. ac_mandatory_list="${ac_mandatory_list} DAHDI"
  7773. ;;
  7774. *)
  7775. DAHDI_DIR="${withval}"
  7776. ac_mandatory_list="${ac_mandatory_list} DAHDI"
  7777. ;;
  7778. esac
  7779. fi
  7780. FFMPEG_DESCRIP="Ffmpeg and avcodec"
  7781. FFMPEG_OPTION="avcodec"
  7782. PBX_FFMPEG=0
  7783. # Check whether --with-avcodec was given.
  7784. if test "${with_avcodec+set}" = set; then :
  7785. withval=$with_avcodec;
  7786. case ${withval} in
  7787. n|no)
  7788. USE_FFMPEG=no
  7789. # -1 is a magic value used by menuselect to know that the package
  7790. # was disabled, other than 'not found'
  7791. PBX_FFMPEG=-1
  7792. ;;
  7793. y|ye|yes)
  7794. ac_mandatory_list="${ac_mandatory_list} FFMPEG"
  7795. ;;
  7796. *)
  7797. FFMPEG_DIR="${withval}"
  7798. ac_mandatory_list="${ac_mandatory_list} FFMPEG"
  7799. ;;
  7800. esac
  7801. fi
  7802. GSM_DESCRIP="External GSM"
  7803. GSM_OPTION="gsm"
  7804. PBX_GSM=0
  7805. # Check whether --with-gsm was given.
  7806. if test "${with_gsm+set}" = set; then :
  7807. withval=$with_gsm;
  7808. case ${withval} in
  7809. n|no)
  7810. USE_GSM=no
  7811. # -1 is a magic value used by menuselect to know that the package
  7812. # was disabled, other than 'not found'
  7813. PBX_GSM=-1
  7814. ;;
  7815. y|ye|yes)
  7816. ac_mandatory_list="${ac_mandatory_list} GSM"
  7817. ;;
  7818. *)
  7819. GSM_DIR="${withval}"
  7820. ac_mandatory_list="${ac_mandatory_list} GSM"
  7821. ;;
  7822. esac
  7823. fi
  7824. ILBC_DESCRIP="System iLBC"
  7825. ILBC_OPTION="ilbc"
  7826. PBX_ILBC=0
  7827. # Check whether --with-ilbc was given.
  7828. if test "${with_ilbc+set}" = set; then :
  7829. withval=$with_ilbc;
  7830. case ${withval} in
  7831. n|no)
  7832. USE_ILBC=no
  7833. # -1 is a magic value used by menuselect to know that the package
  7834. # was disabled, other than 'not found'
  7835. PBX_ILBC=-1
  7836. ;;
  7837. y|ye|yes)
  7838. ac_mandatory_list="${ac_mandatory_list} ILBC"
  7839. ;;
  7840. *)
  7841. ILBC_DIR="${withval}"
  7842. ac_mandatory_list="${ac_mandatory_list} ILBC"
  7843. ;;
  7844. esac
  7845. fi
  7846. GTK2_DESCRIP="gtk2"
  7847. GTK2_OPTION="gtk2"
  7848. PBX_GTK2=0
  7849. # Check whether --with-gtk2 was given.
  7850. if test "${with_gtk2+set}" = set; then :
  7851. withval=$with_gtk2;
  7852. case ${withval} in
  7853. n|no)
  7854. USE_GTK2=no
  7855. # -1 is a magic value used by menuselect to know that the package
  7856. # was disabled, other than 'not found'
  7857. PBX_GTK2=-1
  7858. ;;
  7859. y|ye|yes)
  7860. ac_mandatory_list="${ac_mandatory_list} GTK2"
  7861. ;;
  7862. *)
  7863. GTK2_DIR="${withval}"
  7864. ac_mandatory_list="${ac_mandatory_list} GTK2"
  7865. ;;
  7866. esac
  7867. fi
  7868. GMIME_DESCRIP="GMime"
  7869. GMIME_OPTION="gmime"
  7870. PBX_GMIME=0
  7871. # Check whether --with-gmime was given.
  7872. if test "${with_gmime+set}" = set; then :
  7873. withval=$with_gmime;
  7874. case ${withval} in
  7875. n|no)
  7876. USE_GMIME=no
  7877. # -1 is a magic value used by menuselect to know that the package
  7878. # was disabled, other than 'not found'
  7879. PBX_GMIME=-1
  7880. ;;
  7881. y|ye|yes)
  7882. ac_mandatory_list="${ac_mandatory_list} GMIME"
  7883. ;;
  7884. *)
  7885. GMIME_DIR="${withval}"
  7886. ac_mandatory_list="${ac_mandatory_list} GMIME"
  7887. ;;
  7888. esac
  7889. fi
  7890. OPENH323_DESCRIP="OpenH323"
  7891. OPENH323_OPTION="h323"
  7892. PBX_OPENH323=0
  7893. # Check whether --with-h323 was given.
  7894. if test "${with_h323+set}" = set; then :
  7895. withval=$with_h323;
  7896. case ${withval} in
  7897. n|no)
  7898. USE_OPENH323=no
  7899. # -1 is a magic value used by menuselect to know that the package
  7900. # was disabled, other than 'not found'
  7901. PBX_OPENH323=-1
  7902. ;;
  7903. y|ye|yes)
  7904. ac_mandatory_list="${ac_mandatory_list} OPENH323"
  7905. ;;
  7906. *)
  7907. OPENH323_DIR="${withval}"
  7908. ac_mandatory_list="${ac_mandatory_list} OPENH323"
  7909. ;;
  7910. esac
  7911. fi
  7912. HOARD_DESCRIP="Hoard Memory Allocator"
  7913. HOARD_OPTION="hoard"
  7914. PBX_HOARD=0
  7915. # Check whether --with-hoard was given.
  7916. if test "${with_hoard+set}" = set; then :
  7917. withval=$with_hoard;
  7918. case ${withval} in
  7919. n|no)
  7920. USE_HOARD=no
  7921. # -1 is a magic value used by menuselect to know that the package
  7922. # was disabled, other than 'not found'
  7923. PBX_HOARD=-1
  7924. ;;
  7925. y|ye|yes)
  7926. ac_mandatory_list="${ac_mandatory_list} HOARD"
  7927. ;;
  7928. *)
  7929. HOARD_DIR="${withval}"
  7930. ac_mandatory_list="${ac_mandatory_list} HOARD"
  7931. ;;
  7932. esac
  7933. fi
  7934. ICAL_DESCRIP="iCal"
  7935. ICAL_OPTION="ical"
  7936. PBX_ICAL=0
  7937. # Check whether --with-ical was given.
  7938. if test "${with_ical+set}" = set; then :
  7939. withval=$with_ical;
  7940. case ${withval} in
  7941. n|no)
  7942. USE_ICAL=no
  7943. # -1 is a magic value used by menuselect to know that the package
  7944. # was disabled, other than 'not found'
  7945. PBX_ICAL=-1
  7946. ;;
  7947. y|ye|yes)
  7948. ac_mandatory_list="${ac_mandatory_list} ICAL"
  7949. ;;
  7950. *)
  7951. ICAL_DIR="${withval}"
  7952. ac_mandatory_list="${ac_mandatory_list} ICAL"
  7953. ;;
  7954. esac
  7955. fi
  7956. ICONV_DESCRIP="Iconv"
  7957. ICONV_OPTION="iconv"
  7958. PBX_ICONV=0
  7959. # Check whether --with-iconv was given.
  7960. if test "${with_iconv+set}" = set; then :
  7961. withval=$with_iconv;
  7962. case ${withval} in
  7963. n|no)
  7964. USE_ICONV=no
  7965. # -1 is a magic value used by menuselect to know that the package
  7966. # was disabled, other than 'not found'
  7967. PBX_ICONV=-1
  7968. ;;
  7969. y|ye|yes)
  7970. ac_mandatory_list="${ac_mandatory_list} ICONV"
  7971. ;;
  7972. *)
  7973. ICONV_DIR="${withval}"
  7974. ac_mandatory_list="${ac_mandatory_list} ICONV"
  7975. ;;
  7976. esac
  7977. fi
  7978. IKSEMEL_DESCRIP="Iksemel Jabber"
  7979. IKSEMEL_OPTION="iksemel"
  7980. PBX_IKSEMEL=0
  7981. # Check whether --with-iksemel was given.
  7982. if test "${with_iksemel+set}" = set; then :
  7983. withval=$with_iksemel;
  7984. case ${withval} in
  7985. n|no)
  7986. USE_IKSEMEL=no
  7987. # -1 is a magic value used by menuselect to know that the package
  7988. # was disabled, other than 'not found'
  7989. PBX_IKSEMEL=-1
  7990. ;;
  7991. y|ye|yes)
  7992. ac_mandatory_list="${ac_mandatory_list} IKSEMEL"
  7993. ;;
  7994. *)
  7995. IKSEMEL_DIR="${withval}"
  7996. ac_mandatory_list="${ac_mandatory_list} IKSEMEL"
  7997. ;;
  7998. esac
  7999. fi
  8000. IMAP_TK_DESCRIP="UW IMAP Toolkit"
  8001. IMAP_TK_OPTION="imap"
  8002. PBX_IMAP_TK=0
  8003. # Check whether --with-imap was given.
  8004. if test "${with_imap+set}" = set; then :
  8005. withval=$with_imap;
  8006. case ${withval} in
  8007. n|no)
  8008. USE_IMAP_TK=no
  8009. # -1 is a magic value used by menuselect to know that the package
  8010. # was disabled, other than 'not found'
  8011. PBX_IMAP_TK=-1
  8012. ;;
  8013. y|ye|yes)
  8014. ac_mandatory_list="${ac_mandatory_list} IMAP_TK"
  8015. ;;
  8016. *)
  8017. IMAP_TK_DIR="${withval}"
  8018. ac_mandatory_list="${ac_mandatory_list} IMAP_TK"
  8019. ;;
  8020. esac
  8021. fi
  8022. INOTIFY_DESCRIP="inotify support"
  8023. INOTIFY_OPTION="inotify"
  8024. PBX_INOTIFY=0
  8025. # Check whether --with-inotify was given.
  8026. if test "${with_inotify+set}" = set; then :
  8027. withval=$with_inotify;
  8028. case ${withval} in
  8029. n|no)
  8030. USE_INOTIFY=no
  8031. # -1 is a magic value used by menuselect to know that the package
  8032. # was disabled, other than 'not found'
  8033. PBX_INOTIFY=-1
  8034. ;;
  8035. y|ye|yes)
  8036. ac_mandatory_list="${ac_mandatory_list} INOTIFY"
  8037. ;;
  8038. *)
  8039. INOTIFY_DIR="${withval}"
  8040. ac_mandatory_list="${ac_mandatory_list} INOTIFY"
  8041. ;;
  8042. esac
  8043. fi
  8044. IODBC_DESCRIP="iODBC"
  8045. IODBC_OPTION="iodbc"
  8046. PBX_IODBC=0
  8047. # Check whether --with-iodbc was given.
  8048. if test "${with_iodbc+set}" = set; then :
  8049. withval=$with_iodbc;
  8050. case ${withval} in
  8051. n|no)
  8052. USE_IODBC=no
  8053. # -1 is a magic value used by menuselect to know that the package
  8054. # was disabled, other than 'not found'
  8055. PBX_IODBC=-1
  8056. ;;
  8057. y|ye|yes)
  8058. ac_mandatory_list="${ac_mandatory_list} IODBC"
  8059. ;;
  8060. *)
  8061. IODBC_DIR="${withval}"
  8062. ac_mandatory_list="${ac_mandatory_list} IODBC"
  8063. ;;
  8064. esac
  8065. fi
  8066. ISDNNET_DESCRIP="ISDN4Linux"
  8067. ISDNNET_OPTION="isdnnet"
  8068. PBX_ISDNNET=0
  8069. # Check whether --with-isdnnet was given.
  8070. if test "${with_isdnnet+set}" = set; then :
  8071. withval=$with_isdnnet;
  8072. case ${withval} in
  8073. n|no)
  8074. USE_ISDNNET=no
  8075. # -1 is a magic value used by menuselect to know that the package
  8076. # was disabled, other than 'not found'
  8077. PBX_ISDNNET=-1
  8078. ;;
  8079. y|ye|yes)
  8080. ac_mandatory_list="${ac_mandatory_list} ISDNNET"
  8081. ;;
  8082. *)
  8083. ISDNNET_DIR="${withval}"
  8084. ac_mandatory_list="${ac_mandatory_list} ISDNNET"
  8085. ;;
  8086. esac
  8087. fi
  8088. JACK_DESCRIP="Jack Audio Connection Kit"
  8089. JACK_OPTION="jack"
  8090. PBX_JACK=0
  8091. # Check whether --with-jack was given.
  8092. if test "${with_jack+set}" = set; then :
  8093. withval=$with_jack;
  8094. case ${withval} in
  8095. n|no)
  8096. USE_JACK=no
  8097. # -1 is a magic value used by menuselect to know that the package
  8098. # was disabled, other than 'not found'
  8099. PBX_JACK=-1
  8100. ;;
  8101. y|ye|yes)
  8102. ac_mandatory_list="${ac_mandatory_list} JACK"
  8103. ;;
  8104. *)
  8105. JACK_DIR="${withval}"
  8106. ac_mandatory_list="${ac_mandatory_list} JACK"
  8107. ;;
  8108. esac
  8109. fi
  8110. JANSSON_DESCRIP="Jansson JSON library"
  8111. JANSSON_OPTION="jansson"
  8112. PBX_JANSSON=0
  8113. # Check whether --with-jansson was given.
  8114. if test "${with_jansson+set}" = set; then :
  8115. withval=$with_jansson;
  8116. case ${withval} in
  8117. n|no)
  8118. USE_JANSSON=no
  8119. # -1 is a magic value used by menuselect to know that the package
  8120. # was disabled, other than 'not found'
  8121. PBX_JANSSON=-1
  8122. ;;
  8123. y|ye|yes)
  8124. ac_mandatory_list="${ac_mandatory_list} JANSSON"
  8125. ;;
  8126. *)
  8127. JANSSON_DIR="${withval}"
  8128. ac_mandatory_list="${ac_mandatory_list} JANSSON"
  8129. ;;
  8130. esac
  8131. fi
  8132. URIPARSER_DESCRIP="uriparser library"
  8133. URIPARSER_OPTION="uriparser"
  8134. PBX_URIPARSER=0
  8135. # Check whether --with-uriparser was given.
  8136. if test "${with_uriparser+set}" = set; then :
  8137. withval=$with_uriparser;
  8138. case ${withval} in
  8139. n|no)
  8140. USE_URIPARSER=no
  8141. # -1 is a magic value used by menuselect to know that the package
  8142. # was disabled, other than 'not found'
  8143. PBX_URIPARSER=-1
  8144. ;;
  8145. y|ye|yes)
  8146. ac_mandatory_list="${ac_mandatory_list} URIPARSER"
  8147. ;;
  8148. *)
  8149. URIPARSER_DIR="${withval}"
  8150. ac_mandatory_list="${ac_mandatory_list} URIPARSER"
  8151. ;;
  8152. esac
  8153. fi
  8154. KQUEUE_DESCRIP="kqueue support"
  8155. KQUEUE_OPTION="kqueue"
  8156. PBX_KQUEUE=0
  8157. # Check whether --with-kqueue was given.
  8158. if test "${with_kqueue+set}" = set; then :
  8159. withval=$with_kqueue;
  8160. case ${withval} in
  8161. n|no)
  8162. USE_KQUEUE=no
  8163. # -1 is a magic value used by menuselect to know that the package
  8164. # was disabled, other than 'not found'
  8165. PBX_KQUEUE=-1
  8166. ;;
  8167. y|ye|yes)
  8168. ac_mandatory_list="${ac_mandatory_list} KQUEUE"
  8169. ;;
  8170. *)
  8171. KQUEUE_DIR="${withval}"
  8172. ac_mandatory_list="${ac_mandatory_list} KQUEUE"
  8173. ;;
  8174. esac
  8175. fi
  8176. LDAP_DESCRIP="OpenLDAP"
  8177. LDAP_OPTION="ldap"
  8178. PBX_LDAP=0
  8179. # Check whether --with-ldap was given.
  8180. if test "${with_ldap+set}" = set; then :
  8181. withval=$with_ldap;
  8182. case ${withval} in
  8183. n|no)
  8184. USE_LDAP=no
  8185. # -1 is a magic value used by menuselect to know that the package
  8186. # was disabled, other than 'not found'
  8187. PBX_LDAP=-1
  8188. ;;
  8189. y|ye|yes)
  8190. ac_mandatory_list="${ac_mandatory_list} LDAP"
  8191. ;;
  8192. *)
  8193. LDAP_DIR="${withval}"
  8194. ac_mandatory_list="${ac_mandatory_list} LDAP"
  8195. ;;
  8196. esac
  8197. fi
  8198. # Check whether --with-libcurl was given.
  8199. if test "${with_libcurl+set}" = set; then :
  8200. withval=$with_libcurl; _libcurl_with=$withval
  8201. else
  8202. _libcurl_with=yes
  8203. fi
  8204. if test "$_libcurl_with" != "no" ; then
  8205. for ac_prog in gawk mawk nawk awk
  8206. do
  8207. # Extract the first word of "$ac_prog", so it can be a program name with args.
  8208. set dummy $ac_prog; ac_word=$2
  8209. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  8210. $as_echo_n "checking for $ac_word... " >&6; }
  8211. if ${ac_cv_prog_AWK+:} false; then :
  8212. $as_echo_n "(cached) " >&6
  8213. else
  8214. if test -n "$AWK"; then
  8215. ac_cv_prog_AWK="$AWK" # Let the user override the test.
  8216. else
  8217. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  8218. for as_dir in $PATH
  8219. do
  8220. IFS=$as_save_IFS
  8221. test -z "$as_dir" && as_dir=.
  8222. for ac_exec_ext in '' $ac_executable_extensions; do
  8223. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  8224. ac_cv_prog_AWK="$ac_prog"
  8225. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  8226. break 2
  8227. fi
  8228. done
  8229. done
  8230. IFS=$as_save_IFS
  8231. fi
  8232. fi
  8233. AWK=$ac_cv_prog_AWK
  8234. if test -n "$AWK"; then
  8235. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
  8236. $as_echo "$AWK" >&6; }
  8237. else
  8238. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  8239. $as_echo "no" >&6; }
  8240. fi
  8241. test -n "$AWK" && break
  8242. done
  8243. _libcurl_version_parse="eval $AWK '{split(\$NF,A,\".\"); X=256*256*A[1]+256*A[2]+A[3]; print X;}'"
  8244. _libcurl_try_link=yes
  8245. if test -d "$_libcurl_with" ; then
  8246. CURL_INCLUDE="-I$withval/include"
  8247. _libcurl_ldflags="-L$withval/lib"
  8248. # Extract the first word of "curl-config", so it can be a program name with args.
  8249. set dummy curl-config; ac_word=$2
  8250. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  8251. $as_echo_n "checking for $ac_word... " >&6; }
  8252. if ${ac_cv_path__libcurl_config+:} false; then :
  8253. $as_echo_n "(cached) " >&6
  8254. else
  8255. case $_libcurl_config in
  8256. [\\/]* | ?:[\\/]*)
  8257. ac_cv_path__libcurl_config="$_libcurl_config" # Let the user override the test with a path.
  8258. ;;
  8259. *)
  8260. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  8261. for as_dir in "$withval/bin"
  8262. do
  8263. IFS=$as_save_IFS
  8264. test -z "$as_dir" && as_dir=.
  8265. for ac_exec_ext in '' $ac_executable_extensions; do
  8266. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  8267. ac_cv_path__libcurl_config="$as_dir/$ac_word$ac_exec_ext"
  8268. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  8269. break 2
  8270. fi
  8271. done
  8272. done
  8273. IFS=$as_save_IFS
  8274. test -z "$ac_cv_path__libcurl_config" && ac_cv_path__libcurl_config=""$withval/bin""
  8275. ;;
  8276. esac
  8277. fi
  8278. _libcurl_config=$ac_cv_path__libcurl_config
  8279. if test -n "$_libcurl_config"; then
  8280. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5
  8281. $as_echo "$_libcurl_config" >&6; }
  8282. else
  8283. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  8284. $as_echo "no" >&6; }
  8285. fi
  8286. else
  8287. # Extract the first word of "curl-config", so it can be a program name with args.
  8288. set dummy curl-config; ac_word=$2
  8289. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  8290. $as_echo_n "checking for $ac_word... " >&6; }
  8291. if ${ac_cv_path__libcurl_config+:} false; then :
  8292. $as_echo_n "(cached) " >&6
  8293. else
  8294. case $_libcurl_config in
  8295. [\\/]* | ?:[\\/]*)
  8296. ac_cv_path__libcurl_config="$_libcurl_config" # Let the user override the test with a path.
  8297. ;;
  8298. *)
  8299. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  8300. for as_dir in $PATH
  8301. do
  8302. IFS=$as_save_IFS
  8303. test -z "$as_dir" && as_dir=.
  8304. for ac_exec_ext in '' $ac_executable_extensions; do
  8305. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  8306. ac_cv_path__libcurl_config="$as_dir/$ac_word$ac_exec_ext"
  8307. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  8308. break 2
  8309. fi
  8310. done
  8311. done
  8312. IFS=$as_save_IFS
  8313. ;;
  8314. esac
  8315. fi
  8316. _libcurl_config=$ac_cv_path__libcurl_config
  8317. if test -n "$_libcurl_config"; then
  8318. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_libcurl_config" >&5
  8319. $as_echo "$_libcurl_config" >&6; }
  8320. else
  8321. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  8322. $as_echo "no" >&6; }
  8323. fi
  8324. fi
  8325. if test x$_libcurl_config != "x" ; then
  8326. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the version of libcurl" >&5
  8327. $as_echo_n "checking for the version of libcurl... " >&6; }
  8328. if ${libcurl_cv_lib_curl_version+:} false; then :
  8329. $as_echo_n "(cached) " >&6
  8330. else
  8331. libcurl_cv_lib_curl_version=`$_libcurl_config --version | $AWK '{print $2}'`
  8332. fi
  8333. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_curl_version" >&5
  8334. $as_echo "$libcurl_cv_lib_curl_version" >&6; }
  8335. _libcurl_version=`echo $libcurl_cv_lib_curl_version | $_libcurl_version_parse`
  8336. _libcurl_wanted=`echo 7.10.1 | $_libcurl_version_parse`
  8337. if test $_libcurl_wanted -gt 0 ; then
  8338. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcurl >= version 7.10.1" >&5
  8339. $as_echo_n "checking for libcurl >= version 7.10.1... " >&6; }
  8340. if ${libcurl_cv_lib_version_ok+:} false; then :
  8341. $as_echo_n "(cached) " >&6
  8342. else
  8343. if test $_libcurl_version -ge $_libcurl_wanted ; then
  8344. libcurl_cv_lib_version_ok=yes
  8345. else
  8346. libcurl_cv_lib_version_ok=no
  8347. fi
  8348. fi
  8349. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_version_ok" >&5
  8350. $as_echo "$libcurl_cv_lib_version_ok" >&6; }
  8351. fi
  8352. if test $_libcurl_wanted -eq 0 || test x$libcurl_cv_lib_version_ok = xyes ; then
  8353. if test x"$CURL_INCLUDE" = "x" ; then
  8354. CURL_INCLUDE=`$_libcurl_config --cflags`
  8355. fi
  8356. if test x"$CURL_LIB" = "x" ; then
  8357. CURL_LIB=`$_libcurl_config --libs`
  8358. # This is so silly, but Apple actually has a bug in their
  8359. # curl-config script. Fixed in Tiger, but there are still
  8360. # lots of Panther installs around.
  8361. case "${host}" in
  8362. powerpc-apple-darwin7*)
  8363. CURL_LIB=`echo $CURL_LIB | sed -e 's|-arch i386||g'`
  8364. ;;
  8365. esac
  8366. fi
  8367. # All curl-config scripts support --feature
  8368. _libcurl_features=`$_libcurl_config --feature`
  8369. # Is it modern enough to have --protocols? (7.12.4)
  8370. if test $_libcurl_version -ge 461828 ; then
  8371. _libcurl_protocols=`$_libcurl_config --protocols`
  8372. fi
  8373. else
  8374. _libcurl_try_link=no
  8375. fi
  8376. unset _libcurl_wanted
  8377. fi
  8378. if test $_libcurl_try_link = yes ; then
  8379. # we didn't find curl-config, so let's see if the user-supplied
  8380. # link line (or failing that, "-lcurl") is enough.
  8381. CURL_LIB=${CURL_LIB-"$_libcurl_ldflags -lcurl"}
  8382. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libcurl is usable" >&5
  8383. $as_echo_n "checking whether libcurl is usable... " >&6; }
  8384. if ${libcurl_cv_lib_curl_usable+:} false; then :
  8385. $as_echo_n "(cached) " >&6
  8386. else
  8387. _libcurl_save_cppflags=$CPPFLAGS
  8388. CPPFLAGS="$CURL_INCLUDE $CPPFLAGS"
  8389. _libcurl_save_libs=$LIBS
  8390. LIBS="$CURL_LIB $LIBS"
  8391. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  8392. /* end confdefs.h. */
  8393. #include <curl/curl.h>
  8394. int
  8395. main ()
  8396. {
  8397. /* Try and use a few common options to force a failure if we are
  8398. missing symbols or can't link. */
  8399. int x;
  8400. curl_easy_setopt(NULL,CURLOPT_URL,NULL);
  8401. x=CURL_ERROR_SIZE;
  8402. x=CURLOPT_WRITEFUNCTION;
  8403. x=CURLOPT_FILE;
  8404. x=CURLOPT_ERRORBUFFER;
  8405. x=CURLOPT_STDERR;
  8406. x=CURLOPT_VERBOSE;
  8407. ;
  8408. return 0;
  8409. }
  8410. _ACEOF
  8411. if ac_fn_c_try_link "$LINENO"; then :
  8412. libcurl_cv_lib_curl_usable=yes
  8413. else
  8414. libcurl_cv_lib_curl_usable=no
  8415. fi
  8416. rm -f core conftest.err conftest.$ac_objext \
  8417. conftest$ac_exeext conftest.$ac_ext
  8418. CPPFLAGS=$_libcurl_save_cppflags
  8419. LIBS=$_libcurl_save_libs
  8420. unset _libcurl_save_cppflags
  8421. unset _libcurl_save_libs
  8422. fi
  8423. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libcurl_cv_lib_curl_usable" >&5
  8424. $as_echo "$libcurl_cv_lib_curl_usable" >&6; }
  8425. if test $libcurl_cv_lib_curl_usable = yes ; then
  8426. # Does curl_free() exist in this version of libcurl?
  8427. # If not, fake it with free()
  8428. _libcurl_save_cppflags=$CPPFLAGS
  8429. CPPFLAGS="$CPPFLAGS $CURL_INCLUDE"
  8430. _libcurl_save_libs=$LIBS
  8431. LIBS="$LIBS $CURL_LIB"
  8432. ac_fn_c_check_func "$LINENO" "curl_free" "ac_cv_func_curl_free"
  8433. if test "x$ac_cv_func_curl_free" = xyes; then :
  8434. else
  8435. $as_echo "#define curl_free free" >>confdefs.h
  8436. fi
  8437. CPPFLAGS=$_libcurl_save_cppflags
  8438. LIBS=$_libcurl_save_libs
  8439. unset _libcurl_save_cppflags
  8440. unset _libcurl_save_libs
  8441. $as_echo "#define HAVE_CURL 1" >>confdefs.h
  8442. PBX_CURL=1
  8443. for _libcurl_feature in $_libcurl_features ; do
  8444. cat >>confdefs.h <<_ACEOF
  8445. #define `$as_echo "libcurl_feature_$_libcurl_feature" | $as_tr_cpp` 1
  8446. _ACEOF
  8447. eval `$as_echo "libcurl_feature_$_libcurl_feature" | $as_tr_sh`=yes
  8448. done
  8449. if test "x$_libcurl_protocols" = "x" ; then
  8450. # We don't have --protocols, so just assume that all
  8451. # protocols are available
  8452. _libcurl_protocols="HTTP FTP FILE TELNET LDAP DICT"
  8453. if test x$libcurl_feature_SSL = xyes ; then
  8454. _libcurl_protocols="$_libcurl_protocols HTTPS"
  8455. # FTPS wasn't standards-compliant until version
  8456. # 7.11.0
  8457. if test $_libcurl_version -ge 461568; then
  8458. _libcurl_protocols="$_libcurl_protocols FTPS"
  8459. fi
  8460. fi
  8461. fi
  8462. for _libcurl_protocol in $_libcurl_protocols ; do
  8463. cat >>confdefs.h <<_ACEOF
  8464. #define `$as_echo "libcurl_protocol_$_libcurl_protocol" | $as_tr_cpp` 1
  8465. _ACEOF
  8466. eval `$as_echo "libcurl_protocol_$_libcurl_protocol" | $as_tr_sh`=yes
  8467. done
  8468. else
  8469. unset CURL_LIB
  8470. unset CURL_INCLUDE
  8471. PBX_CURL=0
  8472. fi
  8473. fi
  8474. unset _libcurl_try_link
  8475. unset _libcurl_version_parse
  8476. unset _libcurl_config
  8477. unset _libcurl_feature
  8478. unset _libcurl_features
  8479. unset _libcurl_protocol
  8480. unset _libcurl_protocols
  8481. unset _libcurl_version
  8482. unset _libcurl_ldflags
  8483. fi
  8484. if test x$_libcurl_with = xno || test x$libcurl_cv_lib_curl_usable != xyes ; then
  8485. # This is the IF-NO path
  8486. :
  8487. else
  8488. # This is the IF-YES path
  8489. :
  8490. fi
  8491. unset _libcurl_with
  8492. LIBEDIT_DESCRIP="NetBSD Editline library"
  8493. LIBEDIT_OPTION="libedit"
  8494. PBX_LIBEDIT=0
  8495. # Check whether --with-libedit was given.
  8496. if test "${with_libedit+set}" = set; then :
  8497. withval=$with_libedit;
  8498. case ${withval} in
  8499. n|no)
  8500. USE_LIBEDIT=no
  8501. # -1 is a magic value used by menuselect to know that the package
  8502. # was disabled, other than 'not found'
  8503. PBX_LIBEDIT=-1
  8504. ;;
  8505. y|ye|yes)
  8506. ac_mandatory_list="${ac_mandatory_list} LIBEDIT"
  8507. ;;
  8508. *)
  8509. LIBEDIT_DIR="${withval}"
  8510. ac_mandatory_list="${ac_mandatory_list} LIBEDIT"
  8511. ;;
  8512. esac
  8513. fi
  8514. LIBXML2_DESCRIP="LibXML2"
  8515. LIBXML2_OPTION="libxml2"
  8516. PBX_LIBXML2=0
  8517. # Check whether --with-libxml2 was given.
  8518. if test "${with_libxml2+set}" = set; then :
  8519. withval=$with_libxml2;
  8520. case ${withval} in
  8521. n|no)
  8522. USE_LIBXML2=no
  8523. # -1 is a magic value used by menuselect to know that the package
  8524. # was disabled, other than 'not found'
  8525. PBX_LIBXML2=-1
  8526. ;;
  8527. y|ye|yes)
  8528. ac_mandatory_list="${ac_mandatory_list} LIBXML2"
  8529. ;;
  8530. *)
  8531. LIBXML2_DIR="${withval}"
  8532. ac_mandatory_list="${ac_mandatory_list} LIBXML2"
  8533. ;;
  8534. esac
  8535. fi
  8536. LIBXSLT_DESCRIP="LibXSLT"
  8537. LIBXSLT_OPTION="libxslt"
  8538. PBX_LIBXSLT=0
  8539. # Check whether --with-libxslt was given.
  8540. if test "${with_libxslt+set}" = set; then :
  8541. withval=$with_libxslt;
  8542. case ${withval} in
  8543. n|no)
  8544. USE_LIBXSLT=no
  8545. # -1 is a magic value used by menuselect to know that the package
  8546. # was disabled, other than 'not found'
  8547. PBX_LIBXSLT=-1
  8548. ;;
  8549. y|ye|yes)
  8550. ac_mandatory_list="${ac_mandatory_list} LIBXSLT"
  8551. ;;
  8552. *)
  8553. LIBXSLT_DIR="${withval}"
  8554. ac_mandatory_list="${ac_mandatory_list} LIBXSLT"
  8555. ;;
  8556. esac
  8557. fi
  8558. LIBXSLT_CLEANUP_DESCRIP="LibXSLT Library Cleanup Function"
  8559. LIBXSLT_CLEANUP_OPTION=libxslt
  8560. LIBXSLT_CLEANUP_DIR=${LIBXSLT_DIR}
  8561. PBX_LIBXSLT_CLEANUP=0
  8562. LTDL_DESCRIP="libtool"
  8563. LTDL_OPTION="ltdl"
  8564. PBX_LTDL=0
  8565. # Check whether --with-ltdl was given.
  8566. if test "${with_ltdl+set}" = set; then :
  8567. withval=$with_ltdl;
  8568. case ${withval} in
  8569. n|no)
  8570. USE_LTDL=no
  8571. # -1 is a magic value used by menuselect to know that the package
  8572. # was disabled, other than 'not found'
  8573. PBX_LTDL=-1
  8574. ;;
  8575. y|ye|yes)
  8576. ac_mandatory_list="${ac_mandatory_list} LTDL"
  8577. ;;
  8578. *)
  8579. LTDL_DIR="${withval}"
  8580. ac_mandatory_list="${ac_mandatory_list} LTDL"
  8581. ;;
  8582. esac
  8583. fi
  8584. LUA_DESCRIP="Lua"
  8585. LUA_OPTION="lua"
  8586. PBX_LUA=0
  8587. # Check whether --with-lua was given.
  8588. if test "${with_lua+set}" = set; then :
  8589. withval=$with_lua;
  8590. case ${withval} in
  8591. n|no)
  8592. USE_LUA=no
  8593. # -1 is a magic value used by menuselect to know that the package
  8594. # was disabled, other than 'not found'
  8595. PBX_LUA=-1
  8596. ;;
  8597. y|ye|yes)
  8598. ac_mandatory_list="${ac_mandatory_list} LUA"
  8599. ;;
  8600. *)
  8601. LUA_DIR="${withval}"
  8602. ac_mandatory_list="${ac_mandatory_list} LUA"
  8603. ;;
  8604. esac
  8605. fi
  8606. MISDN_DESCRIP="mISDN user"
  8607. MISDN_OPTION="misdn"
  8608. PBX_MISDN=0
  8609. # Check whether --with-misdn was given.
  8610. if test "${with_misdn+set}" = set; then :
  8611. withval=$with_misdn;
  8612. case ${withval} in
  8613. n|no)
  8614. USE_MISDN=no
  8615. # -1 is a magic value used by menuselect to know that the package
  8616. # was disabled, other than 'not found'
  8617. PBX_MISDN=-1
  8618. ;;
  8619. y|ye|yes)
  8620. ac_mandatory_list="${ac_mandatory_list} MISDN"
  8621. ;;
  8622. *)
  8623. MISDN_DIR="${withval}"
  8624. ac_mandatory_list="${ac_mandatory_list} MISDN"
  8625. ;;
  8626. esac
  8627. fi
  8628. MYSQLCLIENT_DESCRIP="MySQL client"
  8629. MYSQLCLIENT_OPTION="mysqlclient"
  8630. PBX_MYSQLCLIENT=0
  8631. # Check whether --with-mysqlclient was given.
  8632. if test "${with_mysqlclient+set}" = set; then :
  8633. withval=$with_mysqlclient;
  8634. case ${withval} in
  8635. n|no)
  8636. USE_MYSQLCLIENT=no
  8637. # -1 is a magic value used by menuselect to know that the package
  8638. # was disabled, other than 'not found'
  8639. PBX_MYSQLCLIENT=-1
  8640. ;;
  8641. y|ye|yes)
  8642. ac_mandatory_list="${ac_mandatory_list} MYSQLCLIENT"
  8643. ;;
  8644. *)
  8645. MYSQLCLIENT_DIR="${withval}"
  8646. ac_mandatory_list="${ac_mandatory_list} MYSQLCLIENT"
  8647. ;;
  8648. esac
  8649. fi
  8650. NBS_DESCRIP="Network Broadcast Sound"
  8651. NBS_OPTION="nbs"
  8652. PBX_NBS=0
  8653. # Check whether --with-nbs was given.
  8654. if test "${with_nbs+set}" = set; then :
  8655. withval=$with_nbs;
  8656. case ${withval} in
  8657. n|no)
  8658. USE_NBS=no
  8659. # -1 is a magic value used by menuselect to know that the package
  8660. # was disabled, other than 'not found'
  8661. PBX_NBS=-1
  8662. ;;
  8663. y|ye|yes)
  8664. ac_mandatory_list="${ac_mandatory_list} NBS"
  8665. ;;
  8666. *)
  8667. NBS_DIR="${withval}"
  8668. ac_mandatory_list="${ac_mandatory_list} NBS"
  8669. ;;
  8670. esac
  8671. fi
  8672. NCURSES_DESCRIP="ncurses"
  8673. NCURSES_OPTION="ncurses"
  8674. PBX_NCURSES=0
  8675. # Check whether --with-ncurses was given.
  8676. if test "${with_ncurses+set}" = set; then :
  8677. withval=$with_ncurses;
  8678. case ${withval} in
  8679. n|no)
  8680. USE_NCURSES=no
  8681. # -1 is a magic value used by menuselect to know that the package
  8682. # was disabled, other than 'not found'
  8683. PBX_NCURSES=-1
  8684. ;;
  8685. y|ye|yes)
  8686. ac_mandatory_list="${ac_mandatory_list} NCURSES"
  8687. ;;
  8688. *)
  8689. NCURSES_DIR="${withval}"
  8690. ac_mandatory_list="${ac_mandatory_list} NCURSES"
  8691. ;;
  8692. esac
  8693. fi
  8694. NEON_DESCRIP="neon"
  8695. NEON_OPTION="neon"
  8696. PBX_NEON=0
  8697. # Check whether --with-neon was given.
  8698. if test "${with_neon+set}" = set; then :
  8699. withval=$with_neon;
  8700. case ${withval} in
  8701. n|no)
  8702. USE_NEON=no
  8703. # -1 is a magic value used by menuselect to know that the package
  8704. # was disabled, other than 'not found'
  8705. PBX_NEON=-1
  8706. ;;
  8707. y|ye|yes)
  8708. ac_mandatory_list="${ac_mandatory_list} NEON"
  8709. ;;
  8710. *)
  8711. NEON_DIR="${withval}"
  8712. ac_mandatory_list="${ac_mandatory_list} NEON"
  8713. ;;
  8714. esac
  8715. fi
  8716. NEON29_DESCRIP="neon29"
  8717. NEON29_OPTION="neon29"
  8718. PBX_NEON29=0
  8719. # Check whether --with-neon29 was given.
  8720. if test "${with_neon29+set}" = set; then :
  8721. withval=$with_neon29;
  8722. case ${withval} in
  8723. n|no)
  8724. USE_NEON29=no
  8725. # -1 is a magic value used by menuselect to know that the package
  8726. # was disabled, other than 'not found'
  8727. PBX_NEON29=-1
  8728. ;;
  8729. y|ye|yes)
  8730. ac_mandatory_list="${ac_mandatory_list} NEON29"
  8731. ;;
  8732. *)
  8733. NEON29_DIR="${withval}"
  8734. ac_mandatory_list="${ac_mandatory_list} NEON29"
  8735. ;;
  8736. esac
  8737. fi
  8738. NETSNMP_DESCRIP="Net-SNMP"
  8739. NETSNMP_OPTION="netsnmp"
  8740. PBX_NETSNMP=0
  8741. # Check whether --with-netsnmp was given.
  8742. if test "${with_netsnmp+set}" = set; then :
  8743. withval=$with_netsnmp;
  8744. case ${withval} in
  8745. n|no)
  8746. USE_NETSNMP=no
  8747. # -1 is a magic value used by menuselect to know that the package
  8748. # was disabled, other than 'not found'
  8749. PBX_NETSNMP=-1
  8750. ;;
  8751. y|ye|yes)
  8752. ac_mandatory_list="${ac_mandatory_list} NETSNMP"
  8753. ;;
  8754. *)
  8755. NETSNMP_DIR="${withval}"
  8756. ac_mandatory_list="${ac_mandatory_list} NETSNMP"
  8757. ;;
  8758. esac
  8759. fi
  8760. NEWT_DESCRIP="newt"
  8761. NEWT_OPTION="newt"
  8762. PBX_NEWT=0
  8763. # Check whether --with-newt was given.
  8764. if test "${with_newt+set}" = set; then :
  8765. withval=$with_newt;
  8766. case ${withval} in
  8767. n|no)
  8768. USE_NEWT=no
  8769. # -1 is a magic value used by menuselect to know that the package
  8770. # was disabled, other than 'not found'
  8771. PBX_NEWT=-1
  8772. ;;
  8773. y|ye|yes)
  8774. ac_mandatory_list="${ac_mandatory_list} NEWT"
  8775. ;;
  8776. *)
  8777. NEWT_DIR="${withval}"
  8778. ac_mandatory_list="${ac_mandatory_list} NEWT"
  8779. ;;
  8780. esac
  8781. fi
  8782. OGG_DESCRIP="OGG"
  8783. OGG_OPTION="ogg"
  8784. PBX_OGG=0
  8785. # Check whether --with-ogg was given.
  8786. if test "${with_ogg+set}" = set; then :
  8787. withval=$with_ogg;
  8788. case ${withval} in
  8789. n|no)
  8790. USE_OGG=no
  8791. # -1 is a magic value used by menuselect to know that the package
  8792. # was disabled, other than 'not found'
  8793. PBX_OGG=-1
  8794. ;;
  8795. y|ye|yes)
  8796. ac_mandatory_list="${ac_mandatory_list} OGG"
  8797. ;;
  8798. *)
  8799. OGG_DIR="${withval}"
  8800. ac_mandatory_list="${ac_mandatory_list} OGG"
  8801. ;;
  8802. esac
  8803. fi
  8804. OPENR2_DESCRIP="MFR2"
  8805. OPENR2_OPTION="openr2"
  8806. PBX_OPENR2=0
  8807. # Check whether --with-openr2 was given.
  8808. if test "${with_openr2+set}" = set; then :
  8809. withval=$with_openr2;
  8810. case ${withval} in
  8811. n|no)
  8812. USE_OPENR2=no
  8813. # -1 is a magic value used by menuselect to know that the package
  8814. # was disabled, other than 'not found'
  8815. PBX_OPENR2=-1
  8816. ;;
  8817. y|ye|yes)
  8818. ac_mandatory_list="${ac_mandatory_list} OPENR2"
  8819. ;;
  8820. *)
  8821. OPENR2_DIR="${withval}"
  8822. ac_mandatory_list="${ac_mandatory_list} OPENR2"
  8823. ;;
  8824. esac
  8825. fi
  8826. OPUS_DESCRIP="Opus"
  8827. OPUS_OPTION="opus"
  8828. PBX_OPUS=0
  8829. # Check whether --with-opus was given.
  8830. if test "${with_opus+set}" = set; then :
  8831. withval=$with_opus;
  8832. case ${withval} in
  8833. n|no)
  8834. USE_OPUS=no
  8835. # -1 is a magic value used by menuselect to know that the package
  8836. # was disabled, other than 'not found'
  8837. PBX_OPUS=-1
  8838. ;;
  8839. y|ye|yes)
  8840. ac_mandatory_list="${ac_mandatory_list} OPUS"
  8841. ;;
  8842. *)
  8843. OPUS_DIR="${withval}"
  8844. ac_mandatory_list="${ac_mandatory_list} OPUS"
  8845. ;;
  8846. esac
  8847. fi
  8848. OSPTK_DESCRIP="OSP Toolkit"
  8849. OSPTK_OPTION="osptk"
  8850. PBX_OSPTK=0
  8851. # Check whether --with-osptk was given.
  8852. if test "${with_osptk+set}" = set; then :
  8853. withval=$with_osptk;
  8854. case ${withval} in
  8855. n|no)
  8856. USE_OSPTK=no
  8857. # -1 is a magic value used by menuselect to know that the package
  8858. # was disabled, other than 'not found'
  8859. PBX_OSPTK=-1
  8860. ;;
  8861. y|ye|yes)
  8862. ac_mandatory_list="${ac_mandatory_list} OSPTK"
  8863. ;;
  8864. *)
  8865. OSPTK_DIR="${withval}"
  8866. ac_mandatory_list="${ac_mandatory_list} OSPTK"
  8867. ;;
  8868. esac
  8869. fi
  8870. OSS_DESCRIP="Open Sound System"
  8871. OSS_OPTION="oss"
  8872. PBX_OSS=0
  8873. # Check whether --with-oss was given.
  8874. if test "${with_oss+set}" = set; then :
  8875. withval=$with_oss;
  8876. case ${withval} in
  8877. n|no)
  8878. USE_OSS=no
  8879. # -1 is a magic value used by menuselect to know that the package
  8880. # was disabled, other than 'not found'
  8881. PBX_OSS=-1
  8882. ;;
  8883. y|ye|yes)
  8884. ac_mandatory_list="${ac_mandatory_list} OSS"
  8885. ;;
  8886. *)
  8887. OSS_DIR="${withval}"
  8888. ac_mandatory_list="${ac_mandatory_list} OSS"
  8889. ;;
  8890. esac
  8891. fi
  8892. PGSQL_DESCRIP="PostgreSQL"
  8893. PGSQL_OPTION="postgres"
  8894. PBX_PGSQL=0
  8895. # Check whether --with-postgres was given.
  8896. if test "${with_postgres+set}" = set; then :
  8897. withval=$with_postgres;
  8898. case ${withval} in
  8899. n|no)
  8900. USE_PGSQL=no
  8901. # -1 is a magic value used by menuselect to know that the package
  8902. # was disabled, other than 'not found'
  8903. PBX_PGSQL=-1
  8904. ;;
  8905. y|ye|yes)
  8906. ac_mandatory_list="${ac_mandatory_list} PGSQL"
  8907. ;;
  8908. *)
  8909. PGSQL_DIR="${withval}"
  8910. ac_mandatory_list="${ac_mandatory_list} PGSQL"
  8911. ;;
  8912. esac
  8913. fi
  8914. PJPROJECT_DESCRIP="PJPROJECT"
  8915. PJPROJECT_OPTION="pjproject"
  8916. PBX_PJPROJECT=0
  8917. # Check whether --with-pjproject was given.
  8918. if test "${with_pjproject+set}" = set; then :
  8919. withval=$with_pjproject;
  8920. case ${withval} in
  8921. n|no)
  8922. USE_PJPROJECT=no
  8923. # -1 is a magic value used by menuselect to know that the package
  8924. # was disabled, other than 'not found'
  8925. PBX_PJPROJECT=-1
  8926. ;;
  8927. y|ye|yes)
  8928. ac_mandatory_list="${ac_mandatory_list} PJPROJECT"
  8929. ;;
  8930. *)
  8931. PJPROJECT_DIR="${withval}"
  8932. ac_mandatory_list="${ac_mandatory_list} PJPROJECT"
  8933. ;;
  8934. esac
  8935. fi
  8936. POPT_DESCRIP="popt"
  8937. POPT_OPTION="popt"
  8938. PBX_POPT=0
  8939. # Check whether --with-popt was given.
  8940. if test "${with_popt+set}" = set; then :
  8941. withval=$with_popt;
  8942. case ${withval} in
  8943. n|no)
  8944. USE_POPT=no
  8945. # -1 is a magic value used by menuselect to know that the package
  8946. # was disabled, other than 'not found'
  8947. PBX_POPT=-1
  8948. ;;
  8949. y|ye|yes)
  8950. ac_mandatory_list="${ac_mandatory_list} POPT"
  8951. ;;
  8952. *)
  8953. POPT_DIR="${withval}"
  8954. ac_mandatory_list="${ac_mandatory_list} POPT"
  8955. ;;
  8956. esac
  8957. fi
  8958. PJ_TRANSACTION_GRP_LOCK_DESCRIP="PJSIP Transaction Group Lock Support"
  8959. PJ_TRANSACTION_GRP_LOCK_OPTION=pjsip
  8960. PJ_TRANSACTION_GRP_LOCK_DIR=${PJPROJECT_DIR}
  8961. PBX_PJ_TRANSACTION_GRP_LOCK=0
  8962. PJSIP_REPLACE_MEDIA_STREAM_DESCRIP="PJSIP Media Stream Replacement Support"
  8963. PJSIP_REPLACE_MEDIA_STREAM_OPTION=pjsip
  8964. PJSIP_REPLACE_MEDIA_STREAM_DIR=${PJPROJECT_DIR}
  8965. PBX_PJSIP_REPLACE_MEDIA_STREAM=0
  8966. PJSIP_GET_DEST_INFO_DESCRIP="pjsip_get_dest_info support"
  8967. PJSIP_GET_DEST_INFO_OPTION=pjsip
  8968. PJSIP_GET_DEST_INFO_DIR=${PJPROJECT_DIR}
  8969. PBX_PJSIP_GET_DEST_INFO=0
  8970. PJ_SSL_CERT_LOAD_FROM_FILES2_DESCRIP="pj_ssl_cert_load_from_files2 support"
  8971. PJ_SSL_CERT_LOAD_FROM_FILES2_OPTION=pjsip
  8972. PJ_SSL_CERT_LOAD_FROM_FILES2_DIR=${PJPROJECT_DIR}
  8973. PBX_PJ_SSL_CERT_LOAD_FROM_FILES2=0
  8974. PORTAUDIO_DESCRIP="PortAudio"
  8975. PORTAUDIO_OPTION="portaudio"
  8976. PBX_PORTAUDIO=0
  8977. # Check whether --with-portaudio was given.
  8978. if test "${with_portaudio+set}" = set; then :
  8979. withval=$with_portaudio;
  8980. case ${withval} in
  8981. n|no)
  8982. USE_PORTAUDIO=no
  8983. # -1 is a magic value used by menuselect to know that the package
  8984. # was disabled, other than 'not found'
  8985. PBX_PORTAUDIO=-1
  8986. ;;
  8987. y|ye|yes)
  8988. ac_mandatory_list="${ac_mandatory_list} PORTAUDIO"
  8989. ;;
  8990. *)
  8991. PORTAUDIO_DIR="${withval}"
  8992. ac_mandatory_list="${ac_mandatory_list} PORTAUDIO"
  8993. ;;
  8994. esac
  8995. fi
  8996. PRI_DESCRIP="ISDN PRI"
  8997. PRI_OPTION="pri"
  8998. PBX_PRI=0
  8999. # Check whether --with-pri was given.
  9000. if test "${with_pri+set}" = set; then :
  9001. withval=$with_pri;
  9002. case ${withval} in
  9003. n|no)
  9004. USE_PRI=no
  9005. # -1 is a magic value used by menuselect to know that the package
  9006. # was disabled, other than 'not found'
  9007. PBX_PRI=-1
  9008. ;;
  9009. y|ye|yes)
  9010. ac_mandatory_list="${ac_mandatory_list} PRI"
  9011. ;;
  9012. *)
  9013. PRI_DIR="${withval}"
  9014. ac_mandatory_list="${ac_mandatory_list} PRI"
  9015. ;;
  9016. esac
  9017. fi
  9018. PRI_SETUP_ACK_INBAND_DESCRIP="ISDN PRI progress inband ie in SETUP ACK"
  9019. PRI_SETUP_ACK_INBAND_OPTION=pri
  9020. PRI_SETUP_ACK_INBAND_DIR=${PRI_DIR}
  9021. PBX_PRI_SETUP_ACK_INBAND=0
  9022. PRI_L2_PERSISTENCE_DESCRIP="ISDN Layer 2 persistence option"
  9023. PRI_L2_PERSISTENCE_OPTION=pri
  9024. PRI_L2_PERSISTENCE_DIR=${PRI_DIR}
  9025. PBX_PRI_L2_PERSISTENCE=0
  9026. PRI_DATETIME_SEND_DESCRIP="ISDN PRI Date/time ie send policy"
  9027. PRI_DATETIME_SEND_OPTION=pri
  9028. PRI_DATETIME_SEND_DIR=${PRI_DIR}
  9029. PBX_PRI_DATETIME_SEND=0
  9030. PRI_MWI_V2_DESCRIP="ISDN PRI Message Waiting Indication (Fixed)"
  9031. PRI_MWI_V2_OPTION=pri
  9032. PRI_MWI_V2_DIR=${PRI_DIR}
  9033. PBX_PRI_MWI_V2=0
  9034. PRI_DISPLAY_TEXT_DESCRIP="ISDN PRI user display text IE contents during call"
  9035. PRI_DISPLAY_TEXT_OPTION=pri
  9036. PRI_DISPLAY_TEXT_DIR=${PRI_DIR}
  9037. PBX_PRI_DISPLAY_TEXT=0
  9038. PRI_MWI_DESCRIP="ISDN PRI Message Waiting Indication"
  9039. PRI_MWI_OPTION=pri
  9040. PRI_MWI_DIR=${PRI_DIR}
  9041. PBX_PRI_MWI=0
  9042. PRI_MCID_DESCRIP="ISDN PRI Malicious Call ID"
  9043. PRI_MCID_OPTION=pri
  9044. PRI_MCID_DIR=${PRI_DIR}
  9045. PBX_PRI_MCID=0
  9046. PRI_CALL_WAITING_DESCRIP="ISDN PRI call waiting supplementary service"
  9047. PRI_CALL_WAITING_OPTION=pri
  9048. PRI_CALL_WAITING_DIR=${PRI_DIR}
  9049. PBX_PRI_CALL_WAITING=0
  9050. PRI_AOC_EVENTS_DESCRIP="ISDN PRI advice of charge supplementary service events"
  9051. PRI_AOC_EVENTS_OPTION=pri
  9052. PRI_AOC_EVENTS_DIR=${PRI_DIR}
  9053. PBX_PRI_AOC_EVENTS=0
  9054. PRI_TRANSFER_DESCRIP="ISDN PRI call transfer supplementary service"
  9055. PRI_TRANSFER_OPTION=pri
  9056. PRI_TRANSFER_DIR=${PRI_DIR}
  9057. PBX_PRI_TRANSFER=0
  9058. PRI_CCSS_DESCRIP="ISDN PRI call completion supplementary service"
  9059. PRI_CCSS_OPTION=pri
  9060. PRI_CCSS_DIR=${PRI_DIR}
  9061. PBX_PRI_CCSS=0
  9062. PRI_HANGUP_FIX_DESCRIP="ISDN PRI hangup fix"
  9063. PRI_HANGUP_FIX_OPTION=pri
  9064. PRI_HANGUP_FIX_DIR=${PRI_DIR}
  9065. PBX_PRI_HANGUP_FIX=0
  9066. PRI_SUBADDR_DESCRIP="ISDN PRI subaddressing"
  9067. PRI_SUBADDR_OPTION=pri
  9068. PRI_SUBADDR_DIR=${PRI_DIR}
  9069. PBX_PRI_SUBADDR=0
  9070. PRI_CALL_HOLD_DESCRIP="ISDN PRI call hold"
  9071. PRI_CALL_HOLD_OPTION=pri
  9072. PRI_CALL_HOLD_DIR=${PRI_DIR}
  9073. PBX_PRI_CALL_HOLD=0
  9074. PRI_CALL_REROUTING_DESCRIP="ISDN PRI call rerouting and call deflection"
  9075. PRI_CALL_REROUTING_OPTION=pri
  9076. PRI_CALL_REROUTING_DIR=${PRI_DIR}
  9077. PBX_PRI_CALL_REROUTING=0
  9078. PRI_SETUP_KEYPAD_DESCRIP="ISDN PRI keypad facility in SETUP"
  9079. PRI_SETUP_KEYPAD_OPTION=pri
  9080. PRI_SETUP_KEYPAD_DIR=${PRI_DIR}
  9081. PBX_PRI_SETUP_KEYPAD=0
  9082. # ------------------------------------v
  9083. # TODO: The code can be changed to always include these features now.
  9084. # These features will always be present if pri_connected_line_update is available.
  9085. PRI_INBANDDISCONNECT_DESCRIP="ISDN PRI set_inbanddisconnect"
  9086. PRI_INBANDDISCONNECT_OPTION=pri
  9087. PRI_INBANDDISCONNECT_DIR=${PRI_DIR}
  9088. PBX_PRI_INBANDDISCONNECT=0
  9089. PRI_PROG_W_CAUSE_DESCRIP="ISDN progress with cause"
  9090. PRI_PROG_W_CAUSE_OPTION=pri
  9091. PRI_PROG_W_CAUSE_DIR=${PRI_DIR}
  9092. PBX_PRI_PROG_W_CAUSE=0
  9093. PRI_SERVICE_MESSAGES_DESCRIP="ISDN service messages"
  9094. PRI_SERVICE_MESSAGES_OPTION=pri
  9095. PRI_SERVICE_MESSAGES_DIR=${PRI_DIR}
  9096. PBX_PRI_SERVICE_MESSAGES=0
  9097. PRI_REVERSE_CHARGE_DESCRIP="ISDN reverse charge"
  9098. PRI_REVERSE_CHARGE_OPTION=pri
  9099. PRI_REVERSE_CHARGE_DIR=${PRI_DIR}
  9100. PBX_PRI_REVERSE_CHARGE=0
  9101. # ------------------------------------^
  9102. PWLIB_DESCRIP="PWlib"
  9103. PWLIB_OPTION="pwlib"
  9104. PBX_PWLIB=0
  9105. # Check whether --with-pwlib was given.
  9106. if test "${with_pwlib+set}" = set; then :
  9107. withval=$with_pwlib;
  9108. case ${withval} in
  9109. n|no)
  9110. USE_PWLIB=no
  9111. # -1 is a magic value used by menuselect to know that the package
  9112. # was disabled, other than 'not found'
  9113. PBX_PWLIB=-1
  9114. ;;
  9115. y|ye|yes)
  9116. ac_mandatory_list="${ac_mandatory_list} PWLIB"
  9117. ;;
  9118. *)
  9119. PWLIB_DIR="${withval}"
  9120. ac_mandatory_list="${ac_mandatory_list} PWLIB"
  9121. ;;
  9122. esac
  9123. fi
  9124. RADIUS_DESCRIP="Radius Client"
  9125. RADIUS_OPTION="radius"
  9126. PBX_RADIUS=0
  9127. # Check whether --with-radius was given.
  9128. if test "${with_radius+set}" = set; then :
  9129. withval=$with_radius;
  9130. case ${withval} in
  9131. n|no)
  9132. USE_RADIUS=no
  9133. # -1 is a magic value used by menuselect to know that the package
  9134. # was disabled, other than 'not found'
  9135. PBX_RADIUS=-1
  9136. ;;
  9137. y|ye|yes)
  9138. ac_mandatory_list="${ac_mandatory_list} RADIUS"
  9139. ;;
  9140. *)
  9141. RADIUS_DIR="${withval}"
  9142. ac_mandatory_list="${ac_mandatory_list} RADIUS"
  9143. ;;
  9144. esac
  9145. fi
  9146. RESAMPLE_DESCRIP="LIBRESAMPLE"
  9147. RESAMPLE_OPTION="resample"
  9148. PBX_RESAMPLE=0
  9149. # Check whether --with-resample was given.
  9150. if test "${with_resample+set}" = set; then :
  9151. withval=$with_resample;
  9152. case ${withval} in
  9153. n|no)
  9154. USE_RESAMPLE=no
  9155. # -1 is a magic value used by menuselect to know that the package
  9156. # was disabled, other than 'not found'
  9157. PBX_RESAMPLE=-1
  9158. ;;
  9159. y|ye|yes)
  9160. ac_mandatory_list="${ac_mandatory_list} RESAMPLE"
  9161. ;;
  9162. *)
  9163. RESAMPLE_DIR="${withval}"
  9164. ac_mandatory_list="${ac_mandatory_list} RESAMPLE"
  9165. ;;
  9166. esac
  9167. fi
  9168. SDL_DESCRIP="Sdl"
  9169. SDL_OPTION="sdl"
  9170. PBX_SDL=0
  9171. # Check whether --with-sdl was given.
  9172. if test "${with_sdl+set}" = set; then :
  9173. withval=$with_sdl;
  9174. case ${withval} in
  9175. n|no)
  9176. USE_SDL=no
  9177. # -1 is a magic value used by menuselect to know that the package
  9178. # was disabled, other than 'not found'
  9179. PBX_SDL=-1
  9180. ;;
  9181. y|ye|yes)
  9182. ac_mandatory_list="${ac_mandatory_list} SDL"
  9183. ;;
  9184. *)
  9185. SDL_DIR="${withval}"
  9186. ac_mandatory_list="${ac_mandatory_list} SDL"
  9187. ;;
  9188. esac
  9189. fi
  9190. SDL_IMAGE_DESCRIP="Sdl Image"
  9191. SDL_IMAGE_OPTION="SDL_image"
  9192. PBX_SDL_IMAGE=0
  9193. # Check whether --with-SDL_image was given.
  9194. if test "${with_SDL_image+set}" = set; then :
  9195. withval=$with_SDL_image;
  9196. case ${withval} in
  9197. n|no)
  9198. USE_SDL_IMAGE=no
  9199. # -1 is a magic value used by menuselect to know that the package
  9200. # was disabled, other than 'not found'
  9201. PBX_SDL_IMAGE=-1
  9202. ;;
  9203. y|ye|yes)
  9204. ac_mandatory_list="${ac_mandatory_list} SDL_IMAGE"
  9205. ;;
  9206. *)
  9207. SDL_IMAGE_DIR="${withval}"
  9208. ac_mandatory_list="${ac_mandatory_list} SDL_IMAGE"
  9209. ;;
  9210. esac
  9211. fi
  9212. # Check whether --with-sounds-cache was given.
  9213. if test "${with_sounds_cache+set}" = set; then :
  9214. withval=$with_sounds_cache;
  9215. case ${withval} in
  9216. n|no)
  9217. unset SOUNDS_CACHE_DIR
  9218. ;;
  9219. *)
  9220. if test "x${withval}" = "x"; then
  9221. :
  9222. else
  9223. SOUNDS_CACHE_DIR="${withval}"
  9224. fi
  9225. ;;
  9226. esac
  9227. else
  9228. :
  9229. fi
  9230. SPANDSP_DESCRIP="SPANDSP"
  9231. SPANDSP_OPTION="spandsp"
  9232. PBX_SPANDSP=0
  9233. # Check whether --with-spandsp was given.
  9234. if test "${with_spandsp+set}" = set; then :
  9235. withval=$with_spandsp;
  9236. case ${withval} in
  9237. n|no)
  9238. USE_SPANDSP=no
  9239. # -1 is a magic value used by menuselect to know that the package
  9240. # was disabled, other than 'not found'
  9241. PBX_SPANDSP=-1
  9242. ;;
  9243. y|ye|yes)
  9244. ac_mandatory_list="${ac_mandatory_list} SPANDSP"
  9245. ;;
  9246. *)
  9247. SPANDSP_DIR="${withval}"
  9248. ac_mandatory_list="${ac_mandatory_list} SPANDSP"
  9249. ;;
  9250. esac
  9251. fi
  9252. SS7_DESCRIP="ISDN SS7"
  9253. SS7_OPTION="ss7"
  9254. PBX_SS7=0
  9255. # Check whether --with-ss7 was given.
  9256. if test "${with_ss7+set}" = set; then :
  9257. withval=$with_ss7;
  9258. case ${withval} in
  9259. n|no)
  9260. USE_SS7=no
  9261. # -1 is a magic value used by menuselect to know that the package
  9262. # was disabled, other than 'not found'
  9263. PBX_SS7=-1
  9264. ;;
  9265. y|ye|yes)
  9266. ac_mandatory_list="${ac_mandatory_list} SS7"
  9267. ;;
  9268. *)
  9269. SS7_DIR="${withval}"
  9270. ac_mandatory_list="${ac_mandatory_list} SS7"
  9271. ;;
  9272. esac
  9273. fi
  9274. SPEEX_DESCRIP="Speex"
  9275. SPEEX_OPTION="speex"
  9276. PBX_SPEEX=0
  9277. # Check whether --with-speex was given.
  9278. if test "${with_speex+set}" = set; then :
  9279. withval=$with_speex;
  9280. case ${withval} in
  9281. n|no)
  9282. USE_SPEEX=no
  9283. # -1 is a magic value used by menuselect to know that the package
  9284. # was disabled, other than 'not found'
  9285. PBX_SPEEX=-1
  9286. ;;
  9287. y|ye|yes)
  9288. ac_mandatory_list="${ac_mandatory_list} SPEEX"
  9289. ;;
  9290. *)
  9291. SPEEX_DIR="${withval}"
  9292. ac_mandatory_list="${ac_mandatory_list} SPEEX"
  9293. ;;
  9294. esac
  9295. fi
  9296. SPEEX_PREPROCESS_DESCRIP="Speex preprocess routines"
  9297. SPEEX_PREPROCESS_OPTION="speex"
  9298. PBX_SPEEX_PREPROCESS=0
  9299. # Check whether --with-speex was given.
  9300. if test "${with_speex+set}" = set; then :
  9301. withval=$with_speex;
  9302. case ${withval} in
  9303. n|no)
  9304. USE_SPEEX_PREPROCESS=no
  9305. # -1 is a magic value used by menuselect to know that the package
  9306. # was disabled, other than 'not found'
  9307. PBX_SPEEX_PREPROCESS=-1
  9308. ;;
  9309. y|ye|yes)
  9310. ac_mandatory_list="${ac_mandatory_list} SPEEX_PREPROCESS"
  9311. ;;
  9312. *)
  9313. SPEEX_PREPROCESS_DIR="${withval}"
  9314. ac_mandatory_list="${ac_mandatory_list} SPEEX_PREPROCESS"
  9315. ;;
  9316. esac
  9317. fi
  9318. SPEEXDSP_DESCRIP="SpeexDSP"
  9319. SPEEXDSP_OPTION="speexdsp"
  9320. PBX_SPEEXDSP=0
  9321. # Check whether --with-speexdsp was given.
  9322. if test "${with_speexdsp+set}" = set; then :
  9323. withval=$with_speexdsp;
  9324. case ${withval} in
  9325. n|no)
  9326. USE_SPEEXDSP=no
  9327. # -1 is a magic value used by menuselect to know that the package
  9328. # was disabled, other than 'not found'
  9329. PBX_SPEEXDSP=-1
  9330. ;;
  9331. y|ye|yes)
  9332. ac_mandatory_list="${ac_mandatory_list} SPEEXDSP"
  9333. ;;
  9334. *)
  9335. SPEEXDSP_DIR="${withval}"
  9336. ac_mandatory_list="${ac_mandatory_list} SPEEXDSP"
  9337. ;;
  9338. esac
  9339. fi
  9340. SPEEX_PREPROCESS_DESCRIP="speex_preprocess_ctl"
  9341. SPEEX_PREPROCESS_OPTION=speex
  9342. PBX_SPEEX_PREPROCESS=0
  9343. SQLITE_DESCRIP="SQLite"
  9344. SQLITE_OPTION="sqlite"
  9345. PBX_SQLITE=0
  9346. # Check whether --with-sqlite was given.
  9347. if test "${with_sqlite+set}" = set; then :
  9348. withval=$with_sqlite;
  9349. case ${withval} in
  9350. n|no)
  9351. USE_SQLITE=no
  9352. # -1 is a magic value used by menuselect to know that the package
  9353. # was disabled, other than 'not found'
  9354. PBX_SQLITE=-1
  9355. ;;
  9356. y|ye|yes)
  9357. ac_mandatory_list="${ac_mandatory_list} SQLITE"
  9358. ;;
  9359. *)
  9360. SQLITE_DIR="${withval}"
  9361. ac_mandatory_list="${ac_mandatory_list} SQLITE"
  9362. ;;
  9363. esac
  9364. fi
  9365. SQLITE3_DESCRIP="SQLite"
  9366. SQLITE3_OPTION="sqlite3"
  9367. PBX_SQLITE3=0
  9368. # Check whether --with-sqlite3 was given.
  9369. if test "${with_sqlite3+set}" = set; then :
  9370. withval=$with_sqlite3;
  9371. case ${withval} in
  9372. n|no)
  9373. USE_SQLITE3=no
  9374. # -1 is a magic value used by menuselect to know that the package
  9375. # was disabled, other than 'not found'
  9376. PBX_SQLITE3=-1
  9377. ;;
  9378. y|ye|yes)
  9379. ac_mandatory_list="${ac_mandatory_list} SQLITE3"
  9380. ;;
  9381. *)
  9382. SQLITE3_DIR="${withval}"
  9383. ac_mandatory_list="${ac_mandatory_list} SQLITE3"
  9384. ;;
  9385. esac
  9386. fi
  9387. SRTP_DESCRIP="Secure RTP"
  9388. SRTP_OPTION="srtp"
  9389. PBX_SRTP=0
  9390. # Check whether --with-srtp was given.
  9391. if test "${with_srtp+set}" = set; then :
  9392. withval=$with_srtp;
  9393. case ${withval} in
  9394. n|no)
  9395. USE_SRTP=no
  9396. # -1 is a magic value used by menuselect to know that the package
  9397. # was disabled, other than 'not found'
  9398. PBX_SRTP=-1
  9399. ;;
  9400. y|ye|yes)
  9401. ac_mandatory_list="${ac_mandatory_list} SRTP"
  9402. ;;
  9403. *)
  9404. SRTP_DIR="${withval}"
  9405. ac_mandatory_list="${ac_mandatory_list} SRTP"
  9406. ;;
  9407. esac
  9408. fi
  9409. SRTP_SHUTDOWN_DESCRIP="SRTP Library Shutdown Function"
  9410. SRTP_SHUTDOWN_OPTION=srtp
  9411. SRTP_SHUTDOWN_DIR=${SRTP_DIR}
  9412. PBX_SRTP_SHUTDOWN=0
  9413. OPENSSL_DESCRIP="OpenSSL Secure Sockets Layer"
  9414. OPENSSL_OPTION="ssl"
  9415. PBX_OPENSSL=0
  9416. # Check whether --with-ssl was given.
  9417. if test "${with_ssl+set}" = set; then :
  9418. withval=$with_ssl;
  9419. case ${withval} in
  9420. n|no)
  9421. USE_OPENSSL=no
  9422. # -1 is a magic value used by menuselect to know that the package
  9423. # was disabled, other than 'not found'
  9424. PBX_OPENSSL=-1
  9425. ;;
  9426. y|ye|yes)
  9427. ac_mandatory_list="${ac_mandatory_list} OPENSSL"
  9428. ;;
  9429. *)
  9430. OPENSSL_DIR="${withval}"
  9431. ac_mandatory_list="${ac_mandatory_list} OPENSSL"
  9432. ;;
  9433. esac
  9434. fi
  9435. SUPPSERV_DESCRIP="mISDN Supplemental Services"
  9436. SUPPSERV_OPTION="suppserv"
  9437. PBX_SUPPSERV=0
  9438. # Check whether --with-suppserv was given.
  9439. if test "${with_suppserv+set}" = set; then :
  9440. withval=$with_suppserv;
  9441. case ${withval} in
  9442. n|no)
  9443. USE_SUPPSERV=no
  9444. # -1 is a magic value used by menuselect to know that the package
  9445. # was disabled, other than 'not found'
  9446. PBX_SUPPSERV=-1
  9447. ;;
  9448. y|ye|yes)
  9449. ac_mandatory_list="${ac_mandatory_list} SUPPSERV"
  9450. ;;
  9451. *)
  9452. SUPPSERV_DIR="${withval}"
  9453. ac_mandatory_list="${ac_mandatory_list} SUPPSERV"
  9454. ;;
  9455. esac
  9456. fi
  9457. FREETDS_DESCRIP="FreeTDS"
  9458. FREETDS_OPTION="tds"
  9459. PBX_FREETDS=0
  9460. # Check whether --with-tds was given.
  9461. if test "${with_tds+set}" = set; then :
  9462. withval=$with_tds;
  9463. case ${withval} in
  9464. n|no)
  9465. USE_FREETDS=no
  9466. # -1 is a magic value used by menuselect to know that the package
  9467. # was disabled, other than 'not found'
  9468. PBX_FREETDS=-1
  9469. ;;
  9470. y|ye|yes)
  9471. ac_mandatory_list="${ac_mandatory_list} FREETDS"
  9472. ;;
  9473. *)
  9474. FREETDS_DIR="${withval}"
  9475. ac_mandatory_list="${ac_mandatory_list} FREETDS"
  9476. ;;
  9477. esac
  9478. fi
  9479. TERMCAP_DESCRIP="Termcap"
  9480. TERMCAP_OPTION="termcap"
  9481. PBX_TERMCAP=0
  9482. # Check whether --with-termcap was given.
  9483. if test "${with_termcap+set}" = set; then :
  9484. withval=$with_termcap;
  9485. case ${withval} in
  9486. n|no)
  9487. USE_TERMCAP=no
  9488. # -1 is a magic value used by menuselect to know that the package
  9489. # was disabled, other than 'not found'
  9490. PBX_TERMCAP=-1
  9491. ;;
  9492. y|ye|yes)
  9493. ac_mandatory_list="${ac_mandatory_list} TERMCAP"
  9494. ;;
  9495. *)
  9496. TERMCAP_DIR="${withval}"
  9497. ac_mandatory_list="${ac_mandatory_list} TERMCAP"
  9498. ;;
  9499. esac
  9500. fi
  9501. TIMERFD_DESCRIP="timerfd"
  9502. TIMERFD_OPTION="timerfd"
  9503. PBX_TIMERFD=0
  9504. # Check whether --with-timerfd was given.
  9505. if test "${with_timerfd+set}" = set; then :
  9506. withval=$with_timerfd;
  9507. case ${withval} in
  9508. n|no)
  9509. USE_TIMERFD=no
  9510. # -1 is a magic value used by menuselect to know that the package
  9511. # was disabled, other than 'not found'
  9512. PBX_TIMERFD=-1
  9513. ;;
  9514. y|ye|yes)
  9515. ac_mandatory_list="${ac_mandatory_list} TIMERFD"
  9516. ;;
  9517. *)
  9518. TIMERFD_DIR="${withval}"
  9519. ac_mandatory_list="${ac_mandatory_list} TIMERFD"
  9520. ;;
  9521. esac
  9522. fi
  9523. TINFO_DESCRIP="Term Info"
  9524. TINFO_OPTION="tinfo"
  9525. PBX_TINFO=0
  9526. # Check whether --with-tinfo was given.
  9527. if test "${with_tinfo+set}" = set; then :
  9528. withval=$with_tinfo;
  9529. case ${withval} in
  9530. n|no)
  9531. USE_TINFO=no
  9532. # -1 is a magic value used by menuselect to know that the package
  9533. # was disabled, other than 'not found'
  9534. PBX_TINFO=-1
  9535. ;;
  9536. y|ye|yes)
  9537. ac_mandatory_list="${ac_mandatory_list} TINFO"
  9538. ;;
  9539. *)
  9540. TINFO_DIR="${withval}"
  9541. ac_mandatory_list="${ac_mandatory_list} TINFO"
  9542. ;;
  9543. esac
  9544. fi
  9545. TONEZONE_DESCRIP="tonezone"
  9546. TONEZONE_OPTION="tonezone"
  9547. PBX_TONEZONE=0
  9548. # Check whether --with-tonezone was given.
  9549. if test "${with_tonezone+set}" = set; then :
  9550. withval=$with_tonezone;
  9551. case ${withval} in
  9552. n|no)
  9553. USE_TONEZONE=no
  9554. # -1 is a magic value used by menuselect to know that the package
  9555. # was disabled, other than 'not found'
  9556. PBX_TONEZONE=-1
  9557. ;;
  9558. y|ye|yes)
  9559. ac_mandatory_list="${ac_mandatory_list} TONEZONE"
  9560. ;;
  9561. *)
  9562. TONEZONE_DIR="${withval}"
  9563. ac_mandatory_list="${ac_mandatory_list} TONEZONE"
  9564. ;;
  9565. esac
  9566. fi
  9567. UNBOUND_DESCRIP="unbound"
  9568. UNBOUND_OPTION="unbound"
  9569. PBX_UNBOUND=0
  9570. # Check whether --with-unbound was given.
  9571. if test "${with_unbound+set}" = set; then :
  9572. withval=$with_unbound;
  9573. case ${withval} in
  9574. n|no)
  9575. USE_UNBOUND=no
  9576. # -1 is a magic value used by menuselect to know that the package
  9577. # was disabled, other than 'not found'
  9578. PBX_UNBOUND=-1
  9579. ;;
  9580. y|ye|yes)
  9581. ac_mandatory_list="${ac_mandatory_list} UNBOUND"
  9582. ;;
  9583. *)
  9584. UNBOUND_DIR="${withval}"
  9585. ac_mandatory_list="${ac_mandatory_list} UNBOUND"
  9586. ;;
  9587. esac
  9588. fi
  9589. UNIXODBC_DESCRIP="unixODBC"
  9590. UNIXODBC_OPTION="unixodbc"
  9591. PBX_UNIXODBC=0
  9592. # Check whether --with-unixodbc was given.
  9593. if test "${with_unixodbc+set}" = set; then :
  9594. withval=$with_unixodbc;
  9595. case ${withval} in
  9596. n|no)
  9597. USE_UNIXODBC=no
  9598. # -1 is a magic value used by menuselect to know that the package
  9599. # was disabled, other than 'not found'
  9600. PBX_UNIXODBC=-1
  9601. ;;
  9602. y|ye|yes)
  9603. ac_mandatory_list="${ac_mandatory_list} UNIXODBC"
  9604. ;;
  9605. *)
  9606. UNIXODBC_DIR="${withval}"
  9607. ac_mandatory_list="${ac_mandatory_list} UNIXODBC"
  9608. ;;
  9609. esac
  9610. fi
  9611. VORBIS_DESCRIP="Vorbis"
  9612. VORBIS_OPTION="vorbis"
  9613. PBX_VORBIS=0
  9614. # Check whether --with-vorbis was given.
  9615. if test "${with_vorbis+set}" = set; then :
  9616. withval=$with_vorbis;
  9617. case ${withval} in
  9618. n|no)
  9619. USE_VORBIS=no
  9620. # -1 is a magic value used by menuselect to know that the package
  9621. # was disabled, other than 'not found'
  9622. PBX_VORBIS=-1
  9623. ;;
  9624. y|ye|yes)
  9625. ac_mandatory_list="${ac_mandatory_list} VORBIS"
  9626. ;;
  9627. *)
  9628. VORBIS_DIR="${withval}"
  9629. ac_mandatory_list="${ac_mandatory_list} VORBIS"
  9630. ;;
  9631. esac
  9632. fi
  9633. VPB_DESCRIP="Voicetronix API"
  9634. VPB_OPTION="vpb"
  9635. PBX_VPB=0
  9636. # Check whether --with-vpb was given.
  9637. if test "${with_vpb+set}" = set; then :
  9638. withval=$with_vpb;
  9639. case ${withval} in
  9640. n|no)
  9641. USE_VPB=no
  9642. # -1 is a magic value used by menuselect to know that the package
  9643. # was disabled, other than 'not found'
  9644. PBX_VPB=-1
  9645. ;;
  9646. y|ye|yes)
  9647. ac_mandatory_list="${ac_mandatory_list} VPB"
  9648. ;;
  9649. *)
  9650. VPB_DIR="${withval}"
  9651. ac_mandatory_list="${ac_mandatory_list} VPB"
  9652. ;;
  9653. esac
  9654. fi
  9655. X11_DESCRIP="X11"
  9656. X11_OPTION="x11"
  9657. PBX_X11=0
  9658. # Check whether --with-x11 was given.
  9659. if test "${with_x11+set}" = set; then :
  9660. withval=$with_x11;
  9661. case ${withval} in
  9662. n|no)
  9663. USE_X11=no
  9664. # -1 is a magic value used by menuselect to know that the package
  9665. # was disabled, other than 'not found'
  9666. PBX_X11=-1
  9667. ;;
  9668. y|ye|yes)
  9669. ac_mandatory_list="${ac_mandatory_list} X11"
  9670. ;;
  9671. *)
  9672. X11_DIR="${withval}"
  9673. ac_mandatory_list="${ac_mandatory_list} X11"
  9674. ;;
  9675. esac
  9676. fi
  9677. ZLIB_DESCRIP="zlib compression"
  9678. ZLIB_OPTION="z"
  9679. PBX_ZLIB=0
  9680. # Check whether --with-z was given.
  9681. if test "${with_z+set}" = set; then :
  9682. withval=$with_z;
  9683. case ${withval} in
  9684. n|no)
  9685. USE_ZLIB=no
  9686. # -1 is a magic value used by menuselect to know that the package
  9687. # was disabled, other than 'not found'
  9688. PBX_ZLIB=-1
  9689. ;;
  9690. y|ye|yes)
  9691. ac_mandatory_list="${ac_mandatory_list} ZLIB"
  9692. ;;
  9693. *)
  9694. ZLIB_DIR="${withval}"
  9695. ac_mandatory_list="${ac_mandatory_list} ZLIB"
  9696. ;;
  9697. esac
  9698. fi
  9699. # check for basic system features and functionality before
  9700. # checking for package libraries
  9701. ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
  9702. if test "x$ac_cv_type_size_t" = xyes; then :
  9703. else
  9704. cat >>confdefs.h <<_ACEOF
  9705. #define size_t unsigned int
  9706. _ACEOF
  9707. fi
  9708. # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
  9709. # for constant arguments. Useless!
  9710. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
  9711. $as_echo_n "checking for working alloca.h... " >&6; }
  9712. if ${ac_cv_working_alloca_h+:} false; then :
  9713. $as_echo_n "(cached) " >&6
  9714. else
  9715. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9716. /* end confdefs.h. */
  9717. #include <alloca.h>
  9718. int
  9719. main ()
  9720. {
  9721. char *p = (char *) alloca (2 * sizeof (int));
  9722. if (p) return 0;
  9723. ;
  9724. return 0;
  9725. }
  9726. _ACEOF
  9727. if ac_fn_c_try_link "$LINENO"; then :
  9728. ac_cv_working_alloca_h=yes
  9729. else
  9730. ac_cv_working_alloca_h=no
  9731. fi
  9732. rm -f core conftest.err conftest.$ac_objext \
  9733. conftest$ac_exeext conftest.$ac_ext
  9734. fi
  9735. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
  9736. $as_echo "$ac_cv_working_alloca_h" >&6; }
  9737. if test $ac_cv_working_alloca_h = yes; then
  9738. $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
  9739. fi
  9740. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
  9741. $as_echo_n "checking for alloca... " >&6; }
  9742. if ${ac_cv_func_alloca_works+:} false; then :
  9743. $as_echo_n "(cached) " >&6
  9744. else
  9745. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9746. /* end confdefs.h. */
  9747. #ifdef __GNUC__
  9748. # define alloca __builtin_alloca
  9749. #else
  9750. # ifdef _MSC_VER
  9751. # include <malloc.h>
  9752. # define alloca _alloca
  9753. # else
  9754. # ifdef HAVE_ALLOCA_H
  9755. # include <alloca.h>
  9756. # else
  9757. # ifdef _AIX
  9758. #pragma alloca
  9759. # else
  9760. # ifndef alloca /* predefined by HP cc +Olibcalls */
  9761. void *alloca (size_t);
  9762. # endif
  9763. # endif
  9764. # endif
  9765. # endif
  9766. #endif
  9767. int
  9768. main ()
  9769. {
  9770. char *p = (char *) alloca (1);
  9771. if (p) return 0;
  9772. ;
  9773. return 0;
  9774. }
  9775. _ACEOF
  9776. if ac_fn_c_try_link "$LINENO"; then :
  9777. ac_cv_func_alloca_works=yes
  9778. else
  9779. ac_cv_func_alloca_works=no
  9780. fi
  9781. rm -f core conftest.err conftest.$ac_objext \
  9782. conftest$ac_exeext conftest.$ac_ext
  9783. fi
  9784. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
  9785. $as_echo "$ac_cv_func_alloca_works" >&6; }
  9786. if test $ac_cv_func_alloca_works = yes; then
  9787. $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
  9788. else
  9789. # The SVR3 libPW and SVR4 libucb both contain incompatible functions
  9790. # that cause trouble. Some versions do not even contain alloca or
  9791. # contain a buggy version. If you still want to use their alloca,
  9792. # use ar to extract alloca.o from them instead of compiling alloca.c.
  9793. ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
  9794. $as_echo "#define C_ALLOCA 1" >>confdefs.h
  9795. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
  9796. $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
  9797. if ${ac_cv_os_cray+:} false; then :
  9798. $as_echo_n "(cached) " >&6
  9799. else
  9800. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9801. /* end confdefs.h. */
  9802. #if defined CRAY && ! defined CRAY2
  9803. webecray
  9804. #else
  9805. wenotbecray
  9806. #endif
  9807. _ACEOF
  9808. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  9809. $EGREP "webecray" >/dev/null 2>&1; then :
  9810. ac_cv_os_cray=yes
  9811. else
  9812. ac_cv_os_cray=no
  9813. fi
  9814. rm -f conftest*
  9815. fi
  9816. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
  9817. $as_echo "$ac_cv_os_cray" >&6; }
  9818. if test $ac_cv_os_cray = yes; then
  9819. for ac_func in _getb67 GETB67 getb67; do
  9820. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  9821. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  9822. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  9823. cat >>confdefs.h <<_ACEOF
  9824. #define CRAY_STACKSEG_END $ac_func
  9825. _ACEOF
  9826. break
  9827. fi
  9828. done
  9829. fi
  9830. { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
  9831. $as_echo_n "checking stack direction for C alloca... " >&6; }
  9832. if ${ac_cv_c_stack_direction+:} false; then :
  9833. $as_echo_n "(cached) " >&6
  9834. else
  9835. if test "$cross_compiling" = yes; then :
  9836. ac_cv_c_stack_direction=0
  9837. else
  9838. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9839. /* end confdefs.h. */
  9840. $ac_includes_default
  9841. int
  9842. find_stack_direction (int *addr, int depth)
  9843. {
  9844. int dir, dummy = 0;
  9845. if (! addr)
  9846. addr = &dummy;
  9847. *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
  9848. dir = depth ? find_stack_direction (addr, depth - 1) : 0;
  9849. return dir + dummy;
  9850. }
  9851. int
  9852. main (int argc, char **argv)
  9853. {
  9854. return find_stack_direction (0, argc + !argv + 20) < 0;
  9855. }
  9856. _ACEOF
  9857. if ac_fn_c_try_run "$LINENO"; then :
  9858. ac_cv_c_stack_direction=1
  9859. else
  9860. ac_cv_c_stack_direction=-1
  9861. fi
  9862. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  9863. conftest.$ac_objext conftest.beam conftest.$ac_ext
  9864. fi
  9865. fi
  9866. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
  9867. $as_echo "$ac_cv_c_stack_direction" >&6; }
  9868. cat >>confdefs.h <<_ACEOF
  9869. #define STACK_DIRECTION $ac_cv_c_stack_direction
  9870. _ACEOF
  9871. fi
  9872. ac_header_dirent=no
  9873. for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
  9874. as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
  9875. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
  9876. $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
  9877. if eval \${$as_ac_Header+:} false; then :
  9878. $as_echo_n "(cached) " >&6
  9879. else
  9880. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9881. /* end confdefs.h. */
  9882. #include <sys/types.h>
  9883. #include <$ac_hdr>
  9884. int
  9885. main ()
  9886. {
  9887. if ((DIR *) 0)
  9888. return 0;
  9889. ;
  9890. return 0;
  9891. }
  9892. _ACEOF
  9893. if ac_fn_c_try_compile "$LINENO"; then :
  9894. eval "$as_ac_Header=yes"
  9895. else
  9896. eval "$as_ac_Header=no"
  9897. fi
  9898. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  9899. fi
  9900. eval ac_res=\$$as_ac_Header
  9901. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  9902. $as_echo "$ac_res" >&6; }
  9903. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  9904. cat >>confdefs.h <<_ACEOF
  9905. #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
  9906. _ACEOF
  9907. ac_header_dirent=$ac_hdr; break
  9908. fi
  9909. done
  9910. # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
  9911. if test $ac_header_dirent = dirent.h; then
  9912. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
  9913. $as_echo_n "checking for library containing opendir... " >&6; }
  9914. if ${ac_cv_search_opendir+:} false; then :
  9915. $as_echo_n "(cached) " >&6
  9916. else
  9917. ac_func_search_save_LIBS=$LIBS
  9918. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9919. /* end confdefs.h. */
  9920. /* Override any GCC internal prototype to avoid an error.
  9921. Use char because int might match the return type of a GCC
  9922. builtin and then its argument prototype would still apply. */
  9923. #ifdef __cplusplus
  9924. extern "C"
  9925. #endif
  9926. char opendir ();
  9927. int
  9928. main ()
  9929. {
  9930. return opendir ();
  9931. ;
  9932. return 0;
  9933. }
  9934. _ACEOF
  9935. for ac_lib in '' dir; do
  9936. if test -z "$ac_lib"; then
  9937. ac_res="none required"
  9938. else
  9939. ac_res=-l$ac_lib
  9940. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  9941. fi
  9942. if ac_fn_c_try_link "$LINENO"; then :
  9943. ac_cv_search_opendir=$ac_res
  9944. fi
  9945. rm -f core conftest.err conftest.$ac_objext \
  9946. conftest$ac_exeext
  9947. if ${ac_cv_search_opendir+:} false; then :
  9948. break
  9949. fi
  9950. done
  9951. if ${ac_cv_search_opendir+:} false; then :
  9952. else
  9953. ac_cv_search_opendir=no
  9954. fi
  9955. rm conftest.$ac_ext
  9956. LIBS=$ac_func_search_save_LIBS
  9957. fi
  9958. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
  9959. $as_echo "$ac_cv_search_opendir" >&6; }
  9960. ac_res=$ac_cv_search_opendir
  9961. if test "$ac_res" != no; then :
  9962. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  9963. fi
  9964. else
  9965. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
  9966. $as_echo_n "checking for library containing opendir... " >&6; }
  9967. if ${ac_cv_search_opendir+:} false; then :
  9968. $as_echo_n "(cached) " >&6
  9969. else
  9970. ac_func_search_save_LIBS=$LIBS
  9971. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  9972. /* end confdefs.h. */
  9973. /* Override any GCC internal prototype to avoid an error.
  9974. Use char because int might match the return type of a GCC
  9975. builtin and then its argument prototype would still apply. */
  9976. #ifdef __cplusplus
  9977. extern "C"
  9978. #endif
  9979. char opendir ();
  9980. int
  9981. main ()
  9982. {
  9983. return opendir ();
  9984. ;
  9985. return 0;
  9986. }
  9987. _ACEOF
  9988. for ac_lib in '' x; do
  9989. if test -z "$ac_lib"; then
  9990. ac_res="none required"
  9991. else
  9992. ac_res=-l$ac_lib
  9993. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  9994. fi
  9995. if ac_fn_c_try_link "$LINENO"; then :
  9996. ac_cv_search_opendir=$ac_res
  9997. fi
  9998. rm -f core conftest.err conftest.$ac_objext \
  9999. conftest$ac_exeext
  10000. if ${ac_cv_search_opendir+:} false; then :
  10001. break
  10002. fi
  10003. done
  10004. if ${ac_cv_search_opendir+:} false; then :
  10005. else
  10006. ac_cv_search_opendir=no
  10007. fi
  10008. rm conftest.$ac_ext
  10009. LIBS=$ac_func_search_save_LIBS
  10010. fi
  10011. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
  10012. $as_echo "$ac_cv_search_opendir" >&6; }
  10013. ac_res=$ac_cv_search_opendir
  10014. if test "$ac_res" != no; then :
  10015. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  10016. fi
  10017. fi
  10018. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
  10019. $as_echo_n "checking for ANSI C header files... " >&6; }
  10020. if ${ac_cv_header_stdc+:} false; then :
  10021. $as_echo_n "(cached) " >&6
  10022. else
  10023. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10024. /* end confdefs.h. */
  10025. #include <stdlib.h>
  10026. #include <stdarg.h>
  10027. #include <string.h>
  10028. #include <float.h>
  10029. int
  10030. main ()
  10031. {
  10032. ;
  10033. return 0;
  10034. }
  10035. _ACEOF
  10036. if ac_fn_c_try_compile "$LINENO"; then :
  10037. ac_cv_header_stdc=yes
  10038. else
  10039. ac_cv_header_stdc=no
  10040. fi
  10041. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  10042. if test $ac_cv_header_stdc = yes; then
  10043. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  10044. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10045. /* end confdefs.h. */
  10046. #include <string.h>
  10047. _ACEOF
  10048. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  10049. $EGREP "memchr" >/dev/null 2>&1; then :
  10050. else
  10051. ac_cv_header_stdc=no
  10052. fi
  10053. rm -f conftest*
  10054. fi
  10055. if test $ac_cv_header_stdc = yes; then
  10056. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  10057. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10058. /* end confdefs.h. */
  10059. #include <stdlib.h>
  10060. _ACEOF
  10061. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  10062. $EGREP "free" >/dev/null 2>&1; then :
  10063. else
  10064. ac_cv_header_stdc=no
  10065. fi
  10066. rm -f conftest*
  10067. fi
  10068. if test $ac_cv_header_stdc = yes; then
  10069. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  10070. if test "$cross_compiling" = yes; then :
  10071. :
  10072. else
  10073. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10074. /* end confdefs.h. */
  10075. #include <ctype.h>
  10076. #include <stdlib.h>
  10077. #if ((' ' & 0x0FF) == 0x020)
  10078. # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  10079. # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  10080. #else
  10081. # define ISLOWER(c) \
  10082. (('a' <= (c) && (c) <= 'i') \
  10083. || ('j' <= (c) && (c) <= 'r') \
  10084. || ('s' <= (c) && (c) <= 'z'))
  10085. # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
  10086. #endif
  10087. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  10088. int
  10089. main ()
  10090. {
  10091. int i;
  10092. for (i = 0; i < 256; i++)
  10093. if (XOR (islower (i), ISLOWER (i))
  10094. || toupper (i) != TOUPPER (i))
  10095. return 2;
  10096. return 0;
  10097. }
  10098. _ACEOF
  10099. if ac_fn_c_try_run "$LINENO"; then :
  10100. else
  10101. ac_cv_header_stdc=no
  10102. fi
  10103. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  10104. conftest.$ac_objext conftest.beam conftest.$ac_ext
  10105. fi
  10106. fi
  10107. fi
  10108. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
  10109. $as_echo "$ac_cv_header_stdc" >&6; }
  10110. if test $ac_cv_header_stdc = yes; then
  10111. $as_echo "#define STDC_HEADERS 1" >>confdefs.h
  10112. fi
  10113. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
  10114. $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
  10115. if ${ac_cv_header_sys_wait_h+:} false; then :
  10116. $as_echo_n "(cached) " >&6
  10117. else
  10118. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10119. /* end confdefs.h. */
  10120. #include <sys/types.h>
  10121. #include <sys/wait.h>
  10122. #ifndef WEXITSTATUS
  10123. # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
  10124. #endif
  10125. #ifndef WIFEXITED
  10126. # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
  10127. #endif
  10128. int
  10129. main ()
  10130. {
  10131. int s;
  10132. wait (&s);
  10133. s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
  10134. ;
  10135. return 0;
  10136. }
  10137. _ACEOF
  10138. if ac_fn_c_try_compile "$LINENO"; then :
  10139. ac_cv_header_sys_wait_h=yes
  10140. else
  10141. ac_cv_header_sys_wait_h=no
  10142. fi
  10143. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  10144. fi
  10145. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
  10146. $as_echo "$ac_cv_header_sys_wait_h" >&6; }
  10147. if test $ac_cv_header_sys_wait_h = yes; then
  10148. $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
  10149. fi
  10150. 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
  10151. do :
  10152. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  10153. ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
  10154. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  10155. cat >>confdefs.h <<_ACEOF
  10156. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  10157. _ACEOF
  10158. fi
  10159. done
  10160. # Any one of these packages support a mandatory requirement, so we want to check on them as early as possible.
  10161. if test "x${PBX_TERMCAP}" != "x1" -a "${USE_TERMCAP}" != "no"; then
  10162. pbxlibdir=""
  10163. # if --with-TERMCAP=DIR has been specified, use it.
  10164. if test "x${TERMCAP_DIR}" != "x"; then
  10165. if test -d ${TERMCAP_DIR}/lib; then
  10166. pbxlibdir="-L${TERMCAP_DIR}/lib"
  10167. else
  10168. pbxlibdir="-L${TERMCAP_DIR}"
  10169. fi
  10170. fi
  10171. pbxfuncname="tgetent"
  10172. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10173. AST_TERMCAP_FOUND=yes
  10174. else
  10175. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10176. CFLAGS="${CFLAGS} "
  10177. as_ac_Lib=`$as_echo "ac_cv_lib_termcap_${pbxfuncname}" | $as_tr_sh`
  10178. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ltermcap" >&5
  10179. $as_echo_n "checking for ${pbxfuncname} in -ltermcap... " >&6; }
  10180. if eval \${$as_ac_Lib+:} false; then :
  10181. $as_echo_n "(cached) " >&6
  10182. else
  10183. ac_check_lib_save_LIBS=$LIBS
  10184. LIBS="-ltermcap ${pbxlibdir} $LIBS"
  10185. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10186. /* end confdefs.h. */
  10187. /* Override any GCC internal prototype to avoid an error.
  10188. Use char because int might match the return type of a GCC
  10189. builtin and then its argument prototype would still apply. */
  10190. #ifdef __cplusplus
  10191. extern "C"
  10192. #endif
  10193. char ${pbxfuncname} ();
  10194. int
  10195. main ()
  10196. {
  10197. return ${pbxfuncname} ();
  10198. ;
  10199. return 0;
  10200. }
  10201. _ACEOF
  10202. if ac_fn_c_try_link "$LINENO"; then :
  10203. eval "$as_ac_Lib=yes"
  10204. else
  10205. eval "$as_ac_Lib=no"
  10206. fi
  10207. rm -f core conftest.err conftest.$ac_objext \
  10208. conftest$ac_exeext conftest.$ac_ext
  10209. LIBS=$ac_check_lib_save_LIBS
  10210. fi
  10211. eval ac_res=\$$as_ac_Lib
  10212. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10213. $as_echo "$ac_res" >&6; }
  10214. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10215. AST_TERMCAP_FOUND=yes
  10216. else
  10217. AST_TERMCAP_FOUND=no
  10218. fi
  10219. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10220. fi
  10221. # now check for the header.
  10222. if test "${AST_TERMCAP_FOUND}" = "yes"; then
  10223. TERMCAP_LIB="${pbxlibdir} -ltermcap "
  10224. # if --with-TERMCAP=DIR has been specified, use it.
  10225. if test "x${TERMCAP_DIR}" != "x"; then
  10226. TERMCAP_INCLUDE="-I${TERMCAP_DIR}/include"
  10227. fi
  10228. TERMCAP_INCLUDE="${TERMCAP_INCLUDE} "
  10229. if test "x" = "x" ; then # no header, assume found
  10230. TERMCAP_HEADER_FOUND="1"
  10231. else # check for the header
  10232. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10233. CPPFLAGS="${CPPFLAGS} ${TERMCAP_INCLUDE}"
  10234. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  10235. if test "x$ac_cv_header_" = xyes; then :
  10236. TERMCAP_HEADER_FOUND=1
  10237. else
  10238. TERMCAP_HEADER_FOUND=0
  10239. fi
  10240. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10241. fi
  10242. if test "x${TERMCAP_HEADER_FOUND}" = "x0" ; then
  10243. TERMCAP_LIB=""
  10244. TERMCAP_INCLUDE=""
  10245. else
  10246. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10247. TERMCAP_LIB=""
  10248. fi
  10249. PBX_TERMCAP=1
  10250. cat >>confdefs.h <<_ACEOF
  10251. #define HAVE_TERMCAP 1
  10252. _ACEOF
  10253. fi
  10254. fi
  10255. fi
  10256. if test "x${PBX_TINFO}" != "x1" -a "${USE_TINFO}" != "no"; then
  10257. pbxlibdir=""
  10258. # if --with-TINFO=DIR has been specified, use it.
  10259. if test "x${TINFO_DIR}" != "x"; then
  10260. if test -d ${TINFO_DIR}/lib; then
  10261. pbxlibdir="-L${TINFO_DIR}/lib"
  10262. else
  10263. pbxlibdir="-L${TINFO_DIR}"
  10264. fi
  10265. fi
  10266. pbxfuncname="tgetent"
  10267. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10268. AST_TINFO_FOUND=yes
  10269. else
  10270. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10271. CFLAGS="${CFLAGS} "
  10272. as_ac_Lib=`$as_echo "ac_cv_lib_tinfo_${pbxfuncname}" | $as_tr_sh`
  10273. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ltinfo" >&5
  10274. $as_echo_n "checking for ${pbxfuncname} in -ltinfo... " >&6; }
  10275. if eval \${$as_ac_Lib+:} false; then :
  10276. $as_echo_n "(cached) " >&6
  10277. else
  10278. ac_check_lib_save_LIBS=$LIBS
  10279. LIBS="-ltinfo ${pbxlibdir} $LIBS"
  10280. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10281. /* end confdefs.h. */
  10282. /* Override any GCC internal prototype to avoid an error.
  10283. Use char because int might match the return type of a GCC
  10284. builtin and then its argument prototype would still apply. */
  10285. #ifdef __cplusplus
  10286. extern "C"
  10287. #endif
  10288. char ${pbxfuncname} ();
  10289. int
  10290. main ()
  10291. {
  10292. return ${pbxfuncname} ();
  10293. ;
  10294. return 0;
  10295. }
  10296. _ACEOF
  10297. if ac_fn_c_try_link "$LINENO"; then :
  10298. eval "$as_ac_Lib=yes"
  10299. else
  10300. eval "$as_ac_Lib=no"
  10301. fi
  10302. rm -f core conftest.err conftest.$ac_objext \
  10303. conftest$ac_exeext conftest.$ac_ext
  10304. LIBS=$ac_check_lib_save_LIBS
  10305. fi
  10306. eval ac_res=\$$as_ac_Lib
  10307. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10308. $as_echo "$ac_res" >&6; }
  10309. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10310. AST_TINFO_FOUND=yes
  10311. else
  10312. AST_TINFO_FOUND=no
  10313. fi
  10314. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10315. fi
  10316. # now check for the header.
  10317. if test "${AST_TINFO_FOUND}" = "yes"; then
  10318. TINFO_LIB="${pbxlibdir} -ltinfo "
  10319. # if --with-TINFO=DIR has been specified, use it.
  10320. if test "x${TINFO_DIR}" != "x"; then
  10321. TINFO_INCLUDE="-I${TINFO_DIR}/include"
  10322. fi
  10323. TINFO_INCLUDE="${TINFO_INCLUDE} "
  10324. if test "x" = "x" ; then # no header, assume found
  10325. TINFO_HEADER_FOUND="1"
  10326. else # check for the header
  10327. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10328. CPPFLAGS="${CPPFLAGS} ${TINFO_INCLUDE}"
  10329. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  10330. if test "x$ac_cv_header_" = xyes; then :
  10331. TINFO_HEADER_FOUND=1
  10332. else
  10333. TINFO_HEADER_FOUND=0
  10334. fi
  10335. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10336. fi
  10337. if test "x${TINFO_HEADER_FOUND}" = "x0" ; then
  10338. TINFO_LIB=""
  10339. TINFO_INCLUDE=""
  10340. else
  10341. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10342. TINFO_LIB=""
  10343. fi
  10344. PBX_TINFO=1
  10345. cat >>confdefs.h <<_ACEOF
  10346. #define HAVE_TINFO 1
  10347. _ACEOF
  10348. fi
  10349. fi
  10350. fi
  10351. if test "x${PBX_CURSES}" != "x1" -a "${USE_CURSES}" != "no"; then
  10352. pbxlibdir=""
  10353. # if --with-CURSES=DIR has been specified, use it.
  10354. if test "x${CURSES_DIR}" != "x"; then
  10355. if test -d ${CURSES_DIR}/lib; then
  10356. pbxlibdir="-L${CURSES_DIR}/lib"
  10357. else
  10358. pbxlibdir="-L${CURSES_DIR}"
  10359. fi
  10360. fi
  10361. pbxfuncname="initscr"
  10362. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10363. AST_CURSES_FOUND=yes
  10364. else
  10365. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10366. CFLAGS="${CFLAGS} "
  10367. as_ac_Lib=`$as_echo "ac_cv_lib_curses_${pbxfuncname}" | $as_tr_sh`
  10368. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcurses" >&5
  10369. $as_echo_n "checking for ${pbxfuncname} in -lcurses... " >&6; }
  10370. if eval \${$as_ac_Lib+:} false; then :
  10371. $as_echo_n "(cached) " >&6
  10372. else
  10373. ac_check_lib_save_LIBS=$LIBS
  10374. LIBS="-lcurses ${pbxlibdir} $LIBS"
  10375. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10376. /* end confdefs.h. */
  10377. /* Override any GCC internal prototype to avoid an error.
  10378. Use char because int might match the return type of a GCC
  10379. builtin and then its argument prototype would still apply. */
  10380. #ifdef __cplusplus
  10381. extern "C"
  10382. #endif
  10383. char ${pbxfuncname} ();
  10384. int
  10385. main ()
  10386. {
  10387. return ${pbxfuncname} ();
  10388. ;
  10389. return 0;
  10390. }
  10391. _ACEOF
  10392. if ac_fn_c_try_link "$LINENO"; then :
  10393. eval "$as_ac_Lib=yes"
  10394. else
  10395. eval "$as_ac_Lib=no"
  10396. fi
  10397. rm -f core conftest.err conftest.$ac_objext \
  10398. conftest$ac_exeext conftest.$ac_ext
  10399. LIBS=$ac_check_lib_save_LIBS
  10400. fi
  10401. eval ac_res=\$$as_ac_Lib
  10402. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10403. $as_echo "$ac_res" >&6; }
  10404. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10405. AST_CURSES_FOUND=yes
  10406. else
  10407. AST_CURSES_FOUND=no
  10408. fi
  10409. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10410. fi
  10411. # now check for the header.
  10412. if test "${AST_CURSES_FOUND}" = "yes"; then
  10413. CURSES_LIB="${pbxlibdir} -lcurses "
  10414. # if --with-CURSES=DIR has been specified, use it.
  10415. if test "x${CURSES_DIR}" != "x"; then
  10416. CURSES_INCLUDE="-I${CURSES_DIR}/include"
  10417. fi
  10418. CURSES_INCLUDE="${CURSES_INCLUDE} "
  10419. if test "xcurses.h" = "x" ; then # no header, assume found
  10420. CURSES_HEADER_FOUND="1"
  10421. else # check for the header
  10422. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10423. CPPFLAGS="${CPPFLAGS} ${CURSES_INCLUDE}"
  10424. ac_fn_c_check_header_mongrel "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default"
  10425. if test "x$ac_cv_header_curses_h" = xyes; then :
  10426. CURSES_HEADER_FOUND=1
  10427. else
  10428. CURSES_HEADER_FOUND=0
  10429. fi
  10430. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10431. fi
  10432. if test "x${CURSES_HEADER_FOUND}" = "x0" ; then
  10433. CURSES_LIB=""
  10434. CURSES_INCLUDE=""
  10435. else
  10436. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10437. CURSES_LIB=""
  10438. fi
  10439. PBX_CURSES=1
  10440. cat >>confdefs.h <<_ACEOF
  10441. #define HAVE_CURSES 1
  10442. _ACEOF
  10443. fi
  10444. fi
  10445. fi
  10446. if test "x${PBX_NCURSES}" != "x1" -a "${USE_NCURSES}" != "no"; then
  10447. pbxlibdir=""
  10448. # if --with-NCURSES=DIR has been specified, use it.
  10449. if test "x${NCURSES_DIR}" != "x"; then
  10450. if test -d ${NCURSES_DIR}/lib; then
  10451. pbxlibdir="-L${NCURSES_DIR}/lib"
  10452. else
  10453. pbxlibdir="-L${NCURSES_DIR}"
  10454. fi
  10455. fi
  10456. pbxfuncname="initscr"
  10457. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10458. AST_NCURSES_FOUND=yes
  10459. else
  10460. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10461. CFLAGS="${CFLAGS} "
  10462. as_ac_Lib=`$as_echo "ac_cv_lib_ncurses_${pbxfuncname}" | $as_tr_sh`
  10463. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lncurses" >&5
  10464. $as_echo_n "checking for ${pbxfuncname} in -lncurses... " >&6; }
  10465. if eval \${$as_ac_Lib+:} false; then :
  10466. $as_echo_n "(cached) " >&6
  10467. else
  10468. ac_check_lib_save_LIBS=$LIBS
  10469. LIBS="-lncurses ${pbxlibdir} $LIBS"
  10470. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10471. /* end confdefs.h. */
  10472. /* Override any GCC internal prototype to avoid an error.
  10473. Use char because int might match the return type of a GCC
  10474. builtin and then its argument prototype would still apply. */
  10475. #ifdef __cplusplus
  10476. extern "C"
  10477. #endif
  10478. char ${pbxfuncname} ();
  10479. int
  10480. main ()
  10481. {
  10482. return ${pbxfuncname} ();
  10483. ;
  10484. return 0;
  10485. }
  10486. _ACEOF
  10487. if ac_fn_c_try_link "$LINENO"; then :
  10488. eval "$as_ac_Lib=yes"
  10489. else
  10490. eval "$as_ac_Lib=no"
  10491. fi
  10492. rm -f core conftest.err conftest.$ac_objext \
  10493. conftest$ac_exeext conftest.$ac_ext
  10494. LIBS=$ac_check_lib_save_LIBS
  10495. fi
  10496. eval ac_res=\$$as_ac_Lib
  10497. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10498. $as_echo "$ac_res" >&6; }
  10499. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10500. AST_NCURSES_FOUND=yes
  10501. else
  10502. AST_NCURSES_FOUND=no
  10503. fi
  10504. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10505. fi
  10506. # now check for the header.
  10507. if test "${AST_NCURSES_FOUND}" = "yes"; then
  10508. NCURSES_LIB="${pbxlibdir} -lncurses "
  10509. # if --with-NCURSES=DIR has been specified, use it.
  10510. if test "x${NCURSES_DIR}" != "x"; then
  10511. NCURSES_INCLUDE="-I${NCURSES_DIR}/include"
  10512. fi
  10513. NCURSES_INCLUDE="${NCURSES_INCLUDE} "
  10514. if test "xcurses.h" = "x" ; then # no header, assume found
  10515. NCURSES_HEADER_FOUND="1"
  10516. else # check for the header
  10517. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10518. CPPFLAGS="${CPPFLAGS} ${NCURSES_INCLUDE}"
  10519. ac_fn_c_check_header_mongrel "$LINENO" "curses.h" "ac_cv_header_curses_h" "$ac_includes_default"
  10520. if test "x$ac_cv_header_curses_h" = xyes; then :
  10521. NCURSES_HEADER_FOUND=1
  10522. else
  10523. NCURSES_HEADER_FOUND=0
  10524. fi
  10525. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10526. fi
  10527. if test "x${NCURSES_HEADER_FOUND}" = "x0" ; then
  10528. NCURSES_LIB=""
  10529. NCURSES_INCLUDE=""
  10530. else
  10531. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10532. NCURSES_LIB=""
  10533. fi
  10534. PBX_NCURSES=1
  10535. cat >>confdefs.h <<_ACEOF
  10536. #define HAVE_NCURSES 1
  10537. _ACEOF
  10538. fi
  10539. fi
  10540. fi
  10541. EDITLINE_LIB=""
  10542. if test "x$TERMCAP_LIB" != "x" ; then
  10543. EDITLINE_LIB="$TERMCAP_LIB"
  10544. elif test "x$TINFO_LIB" != "x" ; then
  10545. EDITLINE_LIB="$TINFO_LIB"
  10546. elif test "x$CURSES_LIB" != "x" ; then
  10547. EDITLINE_LIB="$CURSES_LIB"
  10548. elif test "x$NCURSES_LIB" != "x" ; then
  10549. EDITLINE_LIB="$NCURSES_LIB"
  10550. else
  10551. as_fn_error $? "*** termcap support not found (on modern systems, this typically means the ncurses development package is missing)" "$LINENO" 5
  10552. fi
  10553. # Find required UUID support.
  10554. # * -luuid on Linux
  10555. # * -le2fs-uuid on OpenBSD
  10556. # * in libsystem on OS X
  10557. if test "x${PBX_LIBUUID}" != "x1" -a "${USE_LIBUUID}" != "no"; then
  10558. pbxlibdir=""
  10559. # if --with-LIBUUID=DIR has been specified, use it.
  10560. if test "x${LIBUUID_DIR}" != "x"; then
  10561. if test -d ${LIBUUID_DIR}/lib; then
  10562. pbxlibdir="-L${LIBUUID_DIR}/lib"
  10563. else
  10564. pbxlibdir="-L${LIBUUID_DIR}"
  10565. fi
  10566. fi
  10567. pbxfuncname="uuid_generate_random"
  10568. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10569. AST_LIBUUID_FOUND=yes
  10570. else
  10571. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10572. CFLAGS="${CFLAGS} "
  10573. as_ac_Lib=`$as_echo "ac_cv_lib_uuid_${pbxfuncname}" | $as_tr_sh`
  10574. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -luuid" >&5
  10575. $as_echo_n "checking for ${pbxfuncname} in -luuid... " >&6; }
  10576. if eval \${$as_ac_Lib+:} false; then :
  10577. $as_echo_n "(cached) " >&6
  10578. else
  10579. ac_check_lib_save_LIBS=$LIBS
  10580. LIBS="-luuid ${pbxlibdir} $LIBS"
  10581. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10582. /* end confdefs.h. */
  10583. /* Override any GCC internal prototype to avoid an error.
  10584. Use char because int might match the return type of a GCC
  10585. builtin and then its argument prototype would still apply. */
  10586. #ifdef __cplusplus
  10587. extern "C"
  10588. #endif
  10589. char ${pbxfuncname} ();
  10590. int
  10591. main ()
  10592. {
  10593. return ${pbxfuncname} ();
  10594. ;
  10595. return 0;
  10596. }
  10597. _ACEOF
  10598. if ac_fn_c_try_link "$LINENO"; then :
  10599. eval "$as_ac_Lib=yes"
  10600. else
  10601. eval "$as_ac_Lib=no"
  10602. fi
  10603. rm -f core conftest.err conftest.$ac_objext \
  10604. conftest$ac_exeext conftest.$ac_ext
  10605. LIBS=$ac_check_lib_save_LIBS
  10606. fi
  10607. eval ac_res=\$$as_ac_Lib
  10608. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10609. $as_echo "$ac_res" >&6; }
  10610. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10611. AST_LIBUUID_FOUND=yes
  10612. else
  10613. AST_LIBUUID_FOUND=no
  10614. fi
  10615. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10616. fi
  10617. # now check for the header.
  10618. if test "${AST_LIBUUID_FOUND}" = "yes"; then
  10619. LIBUUID_LIB="${pbxlibdir} -luuid "
  10620. # if --with-LIBUUID=DIR has been specified, use it.
  10621. if test "x${LIBUUID_DIR}" != "x"; then
  10622. LIBUUID_INCLUDE="-I${LIBUUID_DIR}/include"
  10623. fi
  10624. LIBUUID_INCLUDE="${LIBUUID_INCLUDE} "
  10625. if test "xuuid/uuid.h" = "x" ; then # no header, assume found
  10626. LIBUUID_HEADER_FOUND="1"
  10627. else # check for the header
  10628. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10629. CPPFLAGS="${CPPFLAGS} ${LIBUUID_INCLUDE}"
  10630. ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
  10631. if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
  10632. LIBUUID_HEADER_FOUND=1
  10633. else
  10634. LIBUUID_HEADER_FOUND=0
  10635. fi
  10636. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10637. fi
  10638. if test "x${LIBUUID_HEADER_FOUND}" = "x0" ; then
  10639. LIBUUID_LIB=""
  10640. LIBUUID_INCLUDE=""
  10641. else
  10642. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10643. LIBUUID_LIB=""
  10644. fi
  10645. PBX_LIBUUID=1
  10646. cat >>confdefs.h <<_ACEOF
  10647. #define HAVE_LIBUUID 1
  10648. _ACEOF
  10649. fi
  10650. fi
  10651. fi
  10652. if test "x${PBX_E2FSUUID}" != "x1" -a "${USE_E2FSUUID}" != "no"; then
  10653. pbxlibdir=""
  10654. # if --with-E2FSUUID=DIR has been specified, use it.
  10655. if test "x${E2FSUUID_DIR}" != "x"; then
  10656. if test -d ${E2FSUUID_DIR}/lib; then
  10657. pbxlibdir="-L${E2FSUUID_DIR}/lib"
  10658. else
  10659. pbxlibdir="-L${E2FSUUID_DIR}"
  10660. fi
  10661. fi
  10662. pbxfuncname="uuid_generate_random"
  10663. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10664. AST_E2FSUUID_FOUND=yes
  10665. else
  10666. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10667. CFLAGS="${CFLAGS} "
  10668. as_ac_Lib=`$as_echo "ac_cv_lib_e2fs-uuid_${pbxfuncname}" | $as_tr_sh`
  10669. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -le2fs-uuid" >&5
  10670. $as_echo_n "checking for ${pbxfuncname} in -le2fs-uuid... " >&6; }
  10671. if eval \${$as_ac_Lib+:} false; then :
  10672. $as_echo_n "(cached) " >&6
  10673. else
  10674. ac_check_lib_save_LIBS=$LIBS
  10675. LIBS="-le2fs-uuid ${pbxlibdir} $LIBS"
  10676. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10677. /* end confdefs.h. */
  10678. /* Override any GCC internal prototype to avoid an error.
  10679. Use char because int might match the return type of a GCC
  10680. builtin and then its argument prototype would still apply. */
  10681. #ifdef __cplusplus
  10682. extern "C"
  10683. #endif
  10684. char ${pbxfuncname} ();
  10685. int
  10686. main ()
  10687. {
  10688. return ${pbxfuncname} ();
  10689. ;
  10690. return 0;
  10691. }
  10692. _ACEOF
  10693. if ac_fn_c_try_link "$LINENO"; then :
  10694. eval "$as_ac_Lib=yes"
  10695. else
  10696. eval "$as_ac_Lib=no"
  10697. fi
  10698. rm -f core conftest.err conftest.$ac_objext \
  10699. conftest$ac_exeext conftest.$ac_ext
  10700. LIBS=$ac_check_lib_save_LIBS
  10701. fi
  10702. eval ac_res=\$$as_ac_Lib
  10703. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10704. $as_echo "$ac_res" >&6; }
  10705. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10706. AST_E2FSUUID_FOUND=yes
  10707. else
  10708. AST_E2FSUUID_FOUND=no
  10709. fi
  10710. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10711. fi
  10712. # now check for the header.
  10713. if test "${AST_E2FSUUID_FOUND}" = "yes"; then
  10714. E2FSUUID_LIB="${pbxlibdir} -le2fs-uuid "
  10715. # if --with-E2FSUUID=DIR has been specified, use it.
  10716. if test "x${E2FSUUID_DIR}" != "x"; then
  10717. E2FSUUID_INCLUDE="-I${E2FSUUID_DIR}/include"
  10718. fi
  10719. E2FSUUID_INCLUDE="${E2FSUUID_INCLUDE} "
  10720. if test "xuuid/uuid.h" = "x" ; then # no header, assume found
  10721. E2FSUUID_HEADER_FOUND="1"
  10722. else # check for the header
  10723. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10724. CPPFLAGS="${CPPFLAGS} ${E2FSUUID_INCLUDE}"
  10725. ac_fn_c_check_header_mongrel "$LINENO" "uuid/uuid.h" "ac_cv_header_uuid_uuid_h" "$ac_includes_default"
  10726. if test "x$ac_cv_header_uuid_uuid_h" = xyes; then :
  10727. E2FSUUID_HEADER_FOUND=1
  10728. else
  10729. E2FSUUID_HEADER_FOUND=0
  10730. fi
  10731. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10732. fi
  10733. if test "x${E2FSUUID_HEADER_FOUND}" = "x0" ; then
  10734. E2FSUUID_LIB=""
  10735. E2FSUUID_INCLUDE=""
  10736. else
  10737. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10738. E2FSUUID_LIB=""
  10739. fi
  10740. PBX_E2FSUUID=1
  10741. cat >>confdefs.h <<_ACEOF
  10742. #define HAVE_E2FSUUID 1
  10743. _ACEOF
  10744. fi
  10745. fi
  10746. fi
  10747. for ac_func in uuid_generate_random
  10748. do :
  10749. ac_fn_c_check_func "$LINENO" "uuid_generate_random" "ac_cv_func_uuid_generate_random"
  10750. if test "x$ac_cv_func_uuid_generate_random" = xyes; then :
  10751. cat >>confdefs.h <<_ACEOF
  10752. #define HAVE_UUID_GENERATE_RANDOM 1
  10753. _ACEOF
  10754. SYSUUID=true
  10755. else
  10756. SYSUUID=""
  10757. fi
  10758. done
  10759. if test "x$LIBUUID_LIB" != "x" ; then
  10760. UUID_INCLUDE="$LIBUUID_INCLUDE"
  10761. UUID_LIB="$LIBUUID_LIB"
  10762. elif test "x$E2FSUUID_LIB" != "x" ; then
  10763. UUID_INCLUDE="$E2FSUUID_INCLUDE"
  10764. UUID_LIB="$E2FSUUID_LIB"
  10765. elif test "x$SYSUUID" != "x" ; then
  10766. UUID_INCLUDE=""
  10767. UUID_LIB=""
  10768. else
  10769. as_fn_error $? "*** uuid support not found (this typically means the uuid development package is missing)" "$LINENO" 5
  10770. fi
  10771. # Find required JSON support.
  10772. if test "x${PBX_JANSSON}" != "x1" -a "${USE_JANSSON}" != "no"; then
  10773. pbxlibdir=""
  10774. # if --with-JANSSON=DIR has been specified, use it.
  10775. if test "x${JANSSON_DIR}" != "x"; then
  10776. if test -d ${JANSSON_DIR}/lib; then
  10777. pbxlibdir="-L${JANSSON_DIR}/lib"
  10778. else
  10779. pbxlibdir="-L${JANSSON_DIR}"
  10780. fi
  10781. fi
  10782. pbxfuncname="json_dumps"
  10783. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  10784. AST_JANSSON_FOUND=yes
  10785. else
  10786. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  10787. CFLAGS="${CFLAGS} "
  10788. as_ac_Lib=`$as_echo "ac_cv_lib_jansson_${pbxfuncname}" | $as_tr_sh`
  10789. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ljansson" >&5
  10790. $as_echo_n "checking for ${pbxfuncname} in -ljansson... " >&6; }
  10791. if eval \${$as_ac_Lib+:} false; then :
  10792. $as_echo_n "(cached) " >&6
  10793. else
  10794. ac_check_lib_save_LIBS=$LIBS
  10795. LIBS="-ljansson ${pbxlibdir} $LIBS"
  10796. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10797. /* end confdefs.h. */
  10798. /* Override any GCC internal prototype to avoid an error.
  10799. Use char because int might match the return type of a GCC
  10800. builtin and then its argument prototype would still apply. */
  10801. #ifdef __cplusplus
  10802. extern "C"
  10803. #endif
  10804. char ${pbxfuncname} ();
  10805. int
  10806. main ()
  10807. {
  10808. return ${pbxfuncname} ();
  10809. ;
  10810. return 0;
  10811. }
  10812. _ACEOF
  10813. if ac_fn_c_try_link "$LINENO"; then :
  10814. eval "$as_ac_Lib=yes"
  10815. else
  10816. eval "$as_ac_Lib=no"
  10817. fi
  10818. rm -f core conftest.err conftest.$ac_objext \
  10819. conftest$ac_exeext conftest.$ac_ext
  10820. LIBS=$ac_check_lib_save_LIBS
  10821. fi
  10822. eval ac_res=\$$as_ac_Lib
  10823. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  10824. $as_echo "$ac_res" >&6; }
  10825. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  10826. AST_JANSSON_FOUND=yes
  10827. else
  10828. AST_JANSSON_FOUND=no
  10829. fi
  10830. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  10831. fi
  10832. # now check for the header.
  10833. if test "${AST_JANSSON_FOUND}" = "yes"; then
  10834. JANSSON_LIB="${pbxlibdir} -ljansson "
  10835. # if --with-JANSSON=DIR has been specified, use it.
  10836. if test "x${JANSSON_DIR}" != "x"; then
  10837. JANSSON_INCLUDE="-I${JANSSON_DIR}/include"
  10838. fi
  10839. JANSSON_INCLUDE="${JANSSON_INCLUDE} "
  10840. if test "xjansson.h" = "x" ; then # no header, assume found
  10841. JANSSON_HEADER_FOUND="1"
  10842. else # check for the header
  10843. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  10844. CPPFLAGS="${CPPFLAGS} ${JANSSON_INCLUDE}"
  10845. ac_fn_c_check_header_mongrel "$LINENO" "jansson.h" "ac_cv_header_jansson_h" "$ac_includes_default"
  10846. if test "x$ac_cv_header_jansson_h" = xyes; then :
  10847. JANSSON_HEADER_FOUND=1
  10848. else
  10849. JANSSON_HEADER_FOUND=0
  10850. fi
  10851. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  10852. fi
  10853. if test "x${JANSSON_HEADER_FOUND}" = "x0" ; then
  10854. JANSSON_LIB=""
  10855. JANSSON_INCLUDE=""
  10856. else
  10857. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  10858. JANSSON_LIB=""
  10859. fi
  10860. PBX_JANSSON=1
  10861. cat >>confdefs.h <<_ACEOF
  10862. #define HAVE_JANSSON 1
  10863. _ACEOF
  10864. fi
  10865. fi
  10866. fi
  10867. if test "x$JANSSON_LIB" == "x"; then
  10868. as_fn_error $? "*** JSON support not found (this typically means the libjansson development package is missing)" "$LINENO" 5
  10869. fi
  10870. if test "x${PBX_LIBXML2}" != "x1" -a "${USE_LIBXML2}" != "no"; then
  10871. PBX_LIBXML2=0
  10872. if test -n "$ac_tool_prefix"; then
  10873. # Extract the first word of "${ac_tool_prefix}xml2-config", so it can be a program name with args.
  10874. set dummy ${ac_tool_prefix}xml2-config; ac_word=$2
  10875. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10876. $as_echo_n "checking for $ac_word... " >&6; }
  10877. if ${ac_cv_path_CONFIG_LIBXML2+:} false; then :
  10878. $as_echo_n "(cached) " >&6
  10879. else
  10880. case $CONFIG_LIBXML2 in
  10881. [\\/]* | ?:[\\/]*)
  10882. ac_cv_path_CONFIG_LIBXML2="$CONFIG_LIBXML2" # Let the user override the test with a path.
  10883. ;;
  10884. *)
  10885. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10886. as_dummy="${LIBXML2_DIR}/bin:$PATH"
  10887. for as_dir in $as_dummy
  10888. do
  10889. IFS=$as_save_IFS
  10890. test -z "$as_dir" && as_dir=.
  10891. for ac_exec_ext in '' $ac_executable_extensions; do
  10892. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10893. ac_cv_path_CONFIG_LIBXML2="$as_dir/$ac_word$ac_exec_ext"
  10894. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10895. break 2
  10896. fi
  10897. done
  10898. done
  10899. IFS=$as_save_IFS
  10900. ;;
  10901. esac
  10902. fi
  10903. CONFIG_LIBXML2=$ac_cv_path_CONFIG_LIBXML2
  10904. if test -n "$CONFIG_LIBXML2"; then
  10905. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_LIBXML2" >&5
  10906. $as_echo "$CONFIG_LIBXML2" >&6; }
  10907. else
  10908. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10909. $as_echo "no" >&6; }
  10910. fi
  10911. fi
  10912. if test -z "$ac_cv_path_CONFIG_LIBXML2"; then
  10913. ac_pt_CONFIG_LIBXML2=$CONFIG_LIBXML2
  10914. # Extract the first word of "xml2-config", so it can be a program name with args.
  10915. set dummy xml2-config; ac_word=$2
  10916. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  10917. $as_echo_n "checking for $ac_word... " >&6; }
  10918. if ${ac_cv_path_ac_pt_CONFIG_LIBXML2+:} false; then :
  10919. $as_echo_n "(cached) " >&6
  10920. else
  10921. case $ac_pt_CONFIG_LIBXML2 in
  10922. [\\/]* | ?:[\\/]*)
  10923. ac_cv_path_ac_pt_CONFIG_LIBXML2="$ac_pt_CONFIG_LIBXML2" # Let the user override the test with a path.
  10924. ;;
  10925. *)
  10926. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  10927. as_dummy="${LIBXML2_DIR}/bin:$PATH"
  10928. for as_dir in $as_dummy
  10929. do
  10930. IFS=$as_save_IFS
  10931. test -z "$as_dir" && as_dir=.
  10932. for ac_exec_ext in '' $ac_executable_extensions; do
  10933. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  10934. ac_cv_path_ac_pt_CONFIG_LIBXML2="$as_dir/$ac_word$ac_exec_ext"
  10935. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  10936. break 2
  10937. fi
  10938. done
  10939. done
  10940. IFS=$as_save_IFS
  10941. ;;
  10942. esac
  10943. fi
  10944. ac_pt_CONFIG_LIBXML2=$ac_cv_path_ac_pt_CONFIG_LIBXML2
  10945. if test -n "$ac_pt_CONFIG_LIBXML2"; then
  10946. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_LIBXML2" >&5
  10947. $as_echo "$ac_pt_CONFIG_LIBXML2" >&6; }
  10948. else
  10949. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  10950. $as_echo "no" >&6; }
  10951. fi
  10952. if test "x$ac_pt_CONFIG_LIBXML2" = x; then
  10953. CONFIG_LIBXML2="No"
  10954. else
  10955. case $cross_compiling:$ac_tool_warned in
  10956. yes:)
  10957. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  10958. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  10959. ac_tool_warned=yes ;;
  10960. esac
  10961. CONFIG_LIBXML2=$ac_pt_CONFIG_LIBXML2
  10962. fi
  10963. else
  10964. CONFIG_LIBXML2="$ac_cv_path_CONFIG_LIBXML2"
  10965. fi
  10966. if test ! "x${CONFIG_LIBXML2}" = xNo; then
  10967. if test x"" = x ; then A=--cflags ; else A="" ; fi
  10968. LIBXML2_INCLUDE=$(${CONFIG_LIBXML2} $A)
  10969. LIBXML2_INCLUDE=$(echo ${LIBXML2_INCLUDE} | $SED -e "s|-I|-I${LIBXML2_DIR}|g")
  10970. if test x"" = x ; then A=--libs ; else A="" ; fi
  10971. LIBXML2_LIB=$(${CONFIG_LIBXML2} $A)
  10972. LIBXML2_LIB=$(echo ${LIBXML2_LIB} | $SED -e "s|-L|-L${LIBXML2_DIR}|g")
  10973. if test x"#include <libxml/tree.h>
  10974. #include <libxml/parser.h>" != x ; then
  10975. saved_cppflags="${CPPFLAGS}"
  10976. CPPFLAGS="${CPPFLAGS} ${LIBXML2_INCLUDE}"
  10977. saved_libs="${LIBS}"
  10978. LIBS=${LIBXML2_LIB}
  10979. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  10980. /* end confdefs.h. */
  10981. #include <libxml/tree.h>
  10982. #include <libxml/parser.h>
  10983. int
  10984. main ()
  10985. {
  10986. LIBXML_TEST_VERSION;
  10987. ;
  10988. return 0;
  10989. }
  10990. _ACEOF
  10991. if ac_fn_c_try_link "$LINENO"; then :
  10992. PBX_LIBXML2=1
  10993. $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
  10994. fi
  10995. rm -f core conftest.err conftest.$ac_objext \
  10996. conftest$ac_exeext conftest.$ac_ext
  10997. CPPFLAGS="${saved_cppflags}"
  10998. LIBS="${saved_libs}"
  10999. else
  11000. PBX_LIBXML2=1
  11001. $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
  11002. fi
  11003. fi
  11004. fi
  11005. if test "${PBX_LIBXML2}" != 1; then
  11006. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The Asterisk menuselect tool requires the 'libxml2' development package." >&5
  11007. $as_echo "$as_me: *** The Asterisk menuselect tool requires the 'libxml2' development package." >&6;}
  11008. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Please install the 'libxml2' development package." >&5
  11009. $as_echo "$as_me: *** Please install the 'libxml2' development package." >&6;}
  11010. exit 1
  11011. fi
  11012. if test "x${PBX_URIPARSER}" != "x1" -a "${USE_URIPARSER}" != "no"; then
  11013. pbxlibdir=""
  11014. # if --with-URIPARSER=DIR has been specified, use it.
  11015. if test "x${URIPARSER_DIR}" != "x"; then
  11016. if test -d ${URIPARSER_DIR}/lib; then
  11017. pbxlibdir="-L${URIPARSER_DIR}/lib"
  11018. else
  11019. pbxlibdir="-L${URIPARSER_DIR}"
  11020. fi
  11021. fi
  11022. pbxfuncname="uriParseUriA"
  11023. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  11024. AST_URIPARSER_FOUND=yes
  11025. else
  11026. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  11027. CFLAGS="${CFLAGS} "
  11028. as_ac_Lib=`$as_echo "ac_cv_lib_uriparser_${pbxfuncname}" | $as_tr_sh`
  11029. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -luriparser" >&5
  11030. $as_echo_n "checking for ${pbxfuncname} in -luriparser... " >&6; }
  11031. if eval \${$as_ac_Lib+:} false; then :
  11032. $as_echo_n "(cached) " >&6
  11033. else
  11034. ac_check_lib_save_LIBS=$LIBS
  11035. LIBS="-luriparser ${pbxlibdir} $LIBS"
  11036. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11037. /* end confdefs.h. */
  11038. /* Override any GCC internal prototype to avoid an error.
  11039. Use char because int might match the return type of a GCC
  11040. builtin and then its argument prototype would still apply. */
  11041. #ifdef __cplusplus
  11042. extern "C"
  11043. #endif
  11044. char ${pbxfuncname} ();
  11045. int
  11046. main ()
  11047. {
  11048. return ${pbxfuncname} ();
  11049. ;
  11050. return 0;
  11051. }
  11052. _ACEOF
  11053. if ac_fn_c_try_link "$LINENO"; then :
  11054. eval "$as_ac_Lib=yes"
  11055. else
  11056. eval "$as_ac_Lib=no"
  11057. fi
  11058. rm -f core conftest.err conftest.$ac_objext \
  11059. conftest$ac_exeext conftest.$ac_ext
  11060. LIBS=$ac_check_lib_save_LIBS
  11061. fi
  11062. eval ac_res=\$$as_ac_Lib
  11063. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  11064. $as_echo "$ac_res" >&6; }
  11065. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  11066. AST_URIPARSER_FOUND=yes
  11067. else
  11068. AST_URIPARSER_FOUND=no
  11069. fi
  11070. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  11071. fi
  11072. # now check for the header.
  11073. if test "${AST_URIPARSER_FOUND}" = "yes"; then
  11074. URIPARSER_LIB="${pbxlibdir} -luriparser "
  11075. # if --with-URIPARSER=DIR has been specified, use it.
  11076. if test "x${URIPARSER_DIR}" != "x"; then
  11077. URIPARSER_INCLUDE="-I${URIPARSER_DIR}/include"
  11078. fi
  11079. URIPARSER_INCLUDE="${URIPARSER_INCLUDE} "
  11080. if test "xuriparser/Uri.h" = "x" ; then # no header, assume found
  11081. URIPARSER_HEADER_FOUND="1"
  11082. else # check for the header
  11083. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  11084. CPPFLAGS="${CPPFLAGS} ${URIPARSER_INCLUDE}"
  11085. ac_fn_c_check_header_mongrel "$LINENO" "uriparser/Uri.h" "ac_cv_header_uriparser_Uri_h" "$ac_includes_default"
  11086. if test "x$ac_cv_header_uriparser_Uri_h" = xyes; then :
  11087. URIPARSER_HEADER_FOUND=1
  11088. else
  11089. URIPARSER_HEADER_FOUND=0
  11090. fi
  11091. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  11092. fi
  11093. if test "x${URIPARSER_HEADER_FOUND}" = "x0" ; then
  11094. URIPARSER_LIB=""
  11095. URIPARSER_INCLUDE=""
  11096. else
  11097. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  11098. URIPARSER_LIB=""
  11099. fi
  11100. PBX_URIPARSER=1
  11101. cat >>confdefs.h <<_ACEOF
  11102. #define HAVE_URIPARSER 1
  11103. _ACEOF
  11104. fi
  11105. fi
  11106. fi
  11107. # Another mandatory item (unless it's explicitly disabled)
  11108. # Check whether --enable-xmldoc was given.
  11109. if test "${enable_xmldoc+set}" = set; then :
  11110. enableval=$enable_xmldoc; case "${enableval}" in
  11111. y|ye|yes) disable_xmldoc=no ;;
  11112. n|no) disable_xmldoc=yes ;;
  11113. *) as_fn_error $? "bad value ${enableval} for --disable-xmldoc" "$LINENO" 5 ;;
  11114. esac
  11115. else
  11116. disable_xmldoc=no
  11117. fi
  11118. if test "${disable_xmldoc}" != "yes"; then
  11119. if test "x${PBX_LIBXSLT}" != "x1" -a "${USE_LIBXSLT}" != "no"; then
  11120. pbxlibdir=""
  11121. # if --with-LIBXSLT=DIR has been specified, use it.
  11122. if test "x${LIBXSLT_DIR}" != "x"; then
  11123. if test -d ${LIBXSLT_DIR}/lib; then
  11124. pbxlibdir="-L${LIBXSLT_DIR}/lib"
  11125. else
  11126. pbxlibdir="-L${LIBXSLT_DIR}"
  11127. fi
  11128. fi
  11129. pbxfuncname="xsltLoadStylesheetPI"
  11130. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  11131. AST_LIBXSLT_FOUND=yes
  11132. else
  11133. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  11134. CFLAGS="${CFLAGS} ${LIBXML2_INCLUDE}"
  11135. as_ac_Lib=`$as_echo "ac_cv_lib_xslt_${pbxfuncname}" | $as_tr_sh`
  11136. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lxslt" >&5
  11137. $as_echo_n "checking for ${pbxfuncname} in -lxslt... " >&6; }
  11138. if eval \${$as_ac_Lib+:} false; then :
  11139. $as_echo_n "(cached) " >&6
  11140. else
  11141. ac_check_lib_save_LIBS=$LIBS
  11142. LIBS="-lxslt ${pbxlibdir} ${LIBXML2_LIB} $LIBS"
  11143. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11144. /* end confdefs.h. */
  11145. /* Override any GCC internal prototype to avoid an error.
  11146. Use char because int might match the return type of a GCC
  11147. builtin and then its argument prototype would still apply. */
  11148. #ifdef __cplusplus
  11149. extern "C"
  11150. #endif
  11151. char ${pbxfuncname} ();
  11152. int
  11153. main ()
  11154. {
  11155. return ${pbxfuncname} ();
  11156. ;
  11157. return 0;
  11158. }
  11159. _ACEOF
  11160. if ac_fn_c_try_link "$LINENO"; then :
  11161. eval "$as_ac_Lib=yes"
  11162. else
  11163. eval "$as_ac_Lib=no"
  11164. fi
  11165. rm -f core conftest.err conftest.$ac_objext \
  11166. conftest$ac_exeext conftest.$ac_ext
  11167. LIBS=$ac_check_lib_save_LIBS
  11168. fi
  11169. eval ac_res=\$$as_ac_Lib
  11170. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  11171. $as_echo "$ac_res" >&6; }
  11172. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  11173. AST_LIBXSLT_FOUND=yes
  11174. else
  11175. AST_LIBXSLT_FOUND=no
  11176. fi
  11177. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  11178. fi
  11179. # now check for the header.
  11180. if test "${AST_LIBXSLT_FOUND}" = "yes"; then
  11181. LIBXSLT_LIB="${pbxlibdir} -lxslt ${LIBXML2_LIB}"
  11182. # if --with-LIBXSLT=DIR has been specified, use it.
  11183. if test "x${LIBXSLT_DIR}" != "x"; then
  11184. LIBXSLT_INCLUDE="-I${LIBXSLT_DIR}/include"
  11185. fi
  11186. LIBXSLT_INCLUDE="${LIBXSLT_INCLUDE} ${LIBXML2_INCLUDE}"
  11187. if test "xlibxslt/xsltInternals.h" = "x" ; then # no header, assume found
  11188. LIBXSLT_HEADER_FOUND="1"
  11189. else # check for the header
  11190. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  11191. CPPFLAGS="${CPPFLAGS} ${LIBXSLT_INCLUDE}"
  11192. ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xsltInternals.h" "ac_cv_header_libxslt_xsltInternals_h" "$ac_includes_default"
  11193. if test "x$ac_cv_header_libxslt_xsltInternals_h" = xyes; then :
  11194. LIBXSLT_HEADER_FOUND=1
  11195. else
  11196. LIBXSLT_HEADER_FOUND=0
  11197. fi
  11198. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  11199. fi
  11200. if test "x${LIBXSLT_HEADER_FOUND}" = "x0" ; then
  11201. LIBXSLT_LIB=""
  11202. LIBXSLT_INCLUDE=""
  11203. else
  11204. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  11205. LIBXSLT_LIB=""
  11206. fi
  11207. PBX_LIBXSLT=1
  11208. cat >>confdefs.h <<_ACEOF
  11209. #define HAVE_LIBXSLT 1
  11210. _ACEOF
  11211. fi
  11212. fi
  11213. fi
  11214. if test "x${PBX_LIBXSLT_CLEANUP}" != "x1" -a "${USE_LIBXSLT_CLEANUP}" != "no"; then
  11215. pbxlibdir=""
  11216. # if --with-LIBXSLT_CLEANUP=DIR has been specified, use it.
  11217. if test "x${LIBXSLT_CLEANUP_DIR}" != "x"; then
  11218. if test -d ${LIBXSLT_CLEANUP_DIR}/lib; then
  11219. pbxlibdir="-L${LIBXSLT_CLEANUP_DIR}/lib"
  11220. else
  11221. pbxlibdir="-L${LIBXSLT_CLEANUP_DIR}"
  11222. fi
  11223. fi
  11224. pbxfuncname="xsltCleanupGlobals"
  11225. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  11226. AST_LIBXSLT_CLEANUP_FOUND=yes
  11227. else
  11228. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  11229. CFLAGS="${CFLAGS} ${LIBXML2_INCLUDE}"
  11230. as_ac_Lib=`$as_echo "ac_cv_lib_xslt_${pbxfuncname}" | $as_tr_sh`
  11231. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lxslt" >&5
  11232. $as_echo_n "checking for ${pbxfuncname} in -lxslt... " >&6; }
  11233. if eval \${$as_ac_Lib+:} false; then :
  11234. $as_echo_n "(cached) " >&6
  11235. else
  11236. ac_check_lib_save_LIBS=$LIBS
  11237. LIBS="-lxslt ${pbxlibdir} ${LIBXML2_LIB} $LIBS"
  11238. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11239. /* end confdefs.h. */
  11240. /* Override any GCC internal prototype to avoid an error.
  11241. Use char because int might match the return type of a GCC
  11242. builtin and then its argument prototype would still apply. */
  11243. #ifdef __cplusplus
  11244. extern "C"
  11245. #endif
  11246. char ${pbxfuncname} ();
  11247. int
  11248. main ()
  11249. {
  11250. return ${pbxfuncname} ();
  11251. ;
  11252. return 0;
  11253. }
  11254. _ACEOF
  11255. if ac_fn_c_try_link "$LINENO"; then :
  11256. eval "$as_ac_Lib=yes"
  11257. else
  11258. eval "$as_ac_Lib=no"
  11259. fi
  11260. rm -f core conftest.err conftest.$ac_objext \
  11261. conftest$ac_exeext conftest.$ac_ext
  11262. LIBS=$ac_check_lib_save_LIBS
  11263. fi
  11264. eval ac_res=\$$as_ac_Lib
  11265. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  11266. $as_echo "$ac_res" >&6; }
  11267. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  11268. AST_LIBXSLT_CLEANUP_FOUND=yes
  11269. else
  11270. AST_LIBXSLT_CLEANUP_FOUND=no
  11271. fi
  11272. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  11273. fi
  11274. # now check for the header.
  11275. if test "${AST_LIBXSLT_CLEANUP_FOUND}" = "yes"; then
  11276. LIBXSLT_CLEANUP_LIB="${pbxlibdir} -lxslt ${LIBXML2_LIB}"
  11277. # if --with-LIBXSLT_CLEANUP=DIR has been specified, use it.
  11278. if test "x${LIBXSLT_CLEANUP_DIR}" != "x"; then
  11279. LIBXSLT_CLEANUP_INCLUDE="-I${LIBXSLT_CLEANUP_DIR}/include"
  11280. fi
  11281. LIBXSLT_CLEANUP_INCLUDE="${LIBXSLT_CLEANUP_INCLUDE} ${LIBXML2_INCLUDE}"
  11282. if test "xlibxslt/xsltInternals.h" = "x" ; then # no header, assume found
  11283. LIBXSLT_CLEANUP_HEADER_FOUND="1"
  11284. else # check for the header
  11285. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  11286. CPPFLAGS="${CPPFLAGS} ${LIBXSLT_CLEANUP_INCLUDE}"
  11287. ac_fn_c_check_header_mongrel "$LINENO" "libxslt/xsltInternals.h" "ac_cv_header_libxslt_xsltInternals_h" "$ac_includes_default"
  11288. if test "x$ac_cv_header_libxslt_xsltInternals_h" = xyes; then :
  11289. LIBXSLT_CLEANUP_HEADER_FOUND=1
  11290. else
  11291. LIBXSLT_CLEANUP_HEADER_FOUND=0
  11292. fi
  11293. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  11294. fi
  11295. if test "x${LIBXSLT_CLEANUP_HEADER_FOUND}" = "x0" ; then
  11296. LIBXSLT_CLEANUP_LIB=""
  11297. LIBXSLT_CLEANUP_INCLUDE=""
  11298. else
  11299. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  11300. LIBXSLT_CLEANUP_LIB=""
  11301. fi
  11302. PBX_LIBXSLT_CLEANUP=1
  11303. cat >>confdefs.h <<_ACEOF
  11304. #define HAVE_LIBXSLT_CLEANUP 1
  11305. _ACEOF
  11306. fi
  11307. fi
  11308. fi
  11309. fi
  11310. # some embedded systems omit internationalization (locale) support
  11311. for ac_header in xlocale.h
  11312. do :
  11313. ac_fn_c_check_header_mongrel "$LINENO" "xlocale.h" "ac_cv_header_xlocale_h" "$ac_includes_default"
  11314. if test "x$ac_cv_header_xlocale_h" = xyes; then :
  11315. cat >>confdefs.h <<_ACEOF
  11316. #define HAVE_XLOCALE_H 1
  11317. _ACEOF
  11318. fi
  11319. done
  11320. for ac_header in winsock.h winsock2.h
  11321. do :
  11322. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  11323. ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
  11324. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  11325. cat >>confdefs.h <<_ACEOF
  11326. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  11327. _ACEOF
  11328. fi
  11329. done
  11330. ac_fn_c_check_header_mongrel "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default"
  11331. if test "x$ac_cv_header_sys_poll_h" = xyes; then :
  11332. else
  11333. $as_echo "#define AST_POLL_COMPAT 1" >>confdefs.h
  11334. fi
  11335. # Check whether --enable-largefile was given.
  11336. if test "${enable_largefile+set}" = set; then :
  11337. enableval=$enable_largefile;
  11338. fi
  11339. if test "$enable_largefile" != no; then
  11340. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
  11341. $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
  11342. if ${ac_cv_sys_largefile_CC+:} false; then :
  11343. $as_echo_n "(cached) " >&6
  11344. else
  11345. ac_cv_sys_largefile_CC=no
  11346. if test "$GCC" != yes; then
  11347. ac_save_CC=$CC
  11348. while :; do
  11349. # IRIX 6.2 and later do not support large files by default,
  11350. # so use the C compiler's -n32 option if that helps.
  11351. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11352. /* end confdefs.h. */
  11353. #include <sys/types.h>
  11354. /* Check that off_t can represent 2**63 - 1 correctly.
  11355. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11356. since some C++ compilers masquerading as C compilers
  11357. incorrectly reject 9223372036854775807. */
  11358. #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
  11359. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11360. && LARGE_OFF_T % 2147483647 == 1)
  11361. ? 1 : -1];
  11362. int
  11363. main ()
  11364. {
  11365. ;
  11366. return 0;
  11367. }
  11368. _ACEOF
  11369. if ac_fn_c_try_compile "$LINENO"; then :
  11370. break
  11371. fi
  11372. rm -f core conftest.err conftest.$ac_objext
  11373. CC="$CC -n32"
  11374. if ac_fn_c_try_compile "$LINENO"; then :
  11375. ac_cv_sys_largefile_CC=' -n32'; break
  11376. fi
  11377. rm -f core conftest.err conftest.$ac_objext
  11378. break
  11379. done
  11380. CC=$ac_save_CC
  11381. rm -f conftest.$ac_ext
  11382. fi
  11383. fi
  11384. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
  11385. $as_echo "$ac_cv_sys_largefile_CC" >&6; }
  11386. if test "$ac_cv_sys_largefile_CC" != no; then
  11387. CC=$CC$ac_cv_sys_largefile_CC
  11388. fi
  11389. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
  11390. $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
  11391. if ${ac_cv_sys_file_offset_bits+:} false; then :
  11392. $as_echo_n "(cached) " >&6
  11393. else
  11394. while :; do
  11395. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11396. /* end confdefs.h. */
  11397. #include <sys/types.h>
  11398. /* Check that off_t can represent 2**63 - 1 correctly.
  11399. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11400. since some C++ compilers masquerading as C compilers
  11401. incorrectly reject 9223372036854775807. */
  11402. #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
  11403. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11404. && LARGE_OFF_T % 2147483647 == 1)
  11405. ? 1 : -1];
  11406. int
  11407. main ()
  11408. {
  11409. ;
  11410. return 0;
  11411. }
  11412. _ACEOF
  11413. if ac_fn_c_try_compile "$LINENO"; then :
  11414. ac_cv_sys_file_offset_bits=no; break
  11415. fi
  11416. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11417. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11418. /* end confdefs.h. */
  11419. #define _FILE_OFFSET_BITS 64
  11420. #include <sys/types.h>
  11421. /* Check that off_t can represent 2**63 - 1 correctly.
  11422. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11423. since some C++ compilers masquerading as C compilers
  11424. incorrectly reject 9223372036854775807. */
  11425. #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
  11426. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11427. && LARGE_OFF_T % 2147483647 == 1)
  11428. ? 1 : -1];
  11429. int
  11430. main ()
  11431. {
  11432. ;
  11433. return 0;
  11434. }
  11435. _ACEOF
  11436. if ac_fn_c_try_compile "$LINENO"; then :
  11437. ac_cv_sys_file_offset_bits=64; break
  11438. fi
  11439. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11440. ac_cv_sys_file_offset_bits=unknown
  11441. break
  11442. done
  11443. fi
  11444. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
  11445. $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
  11446. case $ac_cv_sys_file_offset_bits in #(
  11447. no | unknown) ;;
  11448. *)
  11449. cat >>confdefs.h <<_ACEOF
  11450. #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
  11451. _ACEOF
  11452. ;;
  11453. esac
  11454. rm -rf conftest*
  11455. if test $ac_cv_sys_file_offset_bits = unknown; then
  11456. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
  11457. $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
  11458. if ${ac_cv_sys_large_files+:} false; then :
  11459. $as_echo_n "(cached) " >&6
  11460. else
  11461. while :; do
  11462. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11463. /* end confdefs.h. */
  11464. #include <sys/types.h>
  11465. /* Check that off_t can represent 2**63 - 1 correctly.
  11466. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11467. since some C++ compilers masquerading as C compilers
  11468. incorrectly reject 9223372036854775807. */
  11469. #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
  11470. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11471. && LARGE_OFF_T % 2147483647 == 1)
  11472. ? 1 : -1];
  11473. int
  11474. main ()
  11475. {
  11476. ;
  11477. return 0;
  11478. }
  11479. _ACEOF
  11480. if ac_fn_c_try_compile "$LINENO"; then :
  11481. ac_cv_sys_large_files=no; break
  11482. fi
  11483. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11484. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11485. /* end confdefs.h. */
  11486. #define _LARGE_FILES 1
  11487. #include <sys/types.h>
  11488. /* Check that off_t can represent 2**63 - 1 correctly.
  11489. We can't simply define LARGE_OFF_T to be 9223372036854775807,
  11490. since some C++ compilers masquerading as C compilers
  11491. incorrectly reject 9223372036854775807. */
  11492. #define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
  11493. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11494. && LARGE_OFF_T % 2147483647 == 1)
  11495. ? 1 : -1];
  11496. int
  11497. main ()
  11498. {
  11499. ;
  11500. return 0;
  11501. }
  11502. _ACEOF
  11503. if ac_fn_c_try_compile "$LINENO"; then :
  11504. ac_cv_sys_large_files=1; break
  11505. fi
  11506. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11507. ac_cv_sys_large_files=unknown
  11508. break
  11509. done
  11510. fi
  11511. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
  11512. $as_echo "$ac_cv_sys_large_files" >&6; }
  11513. case $ac_cv_sys_large_files in #(
  11514. no | unknown) ;;
  11515. *)
  11516. cat >>confdefs.h <<_ACEOF
  11517. #define _LARGE_FILES $ac_cv_sys_large_files
  11518. _ACEOF
  11519. ;;
  11520. esac
  11521. rm -rf conftest*
  11522. fi
  11523. fi
  11524. # Checks for typedefs, structures, and compiler characteristics.
  11525. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
  11526. $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
  11527. if ${ac_cv_header_stdbool_h+:} false; then :
  11528. $as_echo_n "(cached) " >&6
  11529. else
  11530. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11531. /* end confdefs.h. */
  11532. #include <stdbool.h>
  11533. #ifndef bool
  11534. "error: bool is not defined"
  11535. #endif
  11536. #ifndef false
  11537. "error: false is not defined"
  11538. #endif
  11539. #if false
  11540. "error: false is not 0"
  11541. #endif
  11542. #ifndef true
  11543. "error: true is not defined"
  11544. #endif
  11545. #if true != 1
  11546. "error: true is not 1"
  11547. #endif
  11548. #ifndef __bool_true_false_are_defined
  11549. "error: __bool_true_false_are_defined is not defined"
  11550. #endif
  11551. struct s { _Bool s: 1; _Bool t; } s;
  11552. char a[true == 1 ? 1 : -1];
  11553. char b[false == 0 ? 1 : -1];
  11554. char c[__bool_true_false_are_defined == 1 ? 1 : -1];
  11555. char d[(bool) 0.5 == true ? 1 : -1];
  11556. /* See body of main program for 'e'. */
  11557. char f[(_Bool) 0.0 == false ? 1 : -1];
  11558. char g[true];
  11559. char h[sizeof (_Bool)];
  11560. char i[sizeof s.t];
  11561. enum { j = false, k = true, l = false * true, m = true * 256 };
  11562. /* The following fails for
  11563. HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
  11564. _Bool n[m];
  11565. char o[sizeof n == m * sizeof n[0] ? 1 : -1];
  11566. char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
  11567. /* Catch a bug in an HP-UX C compiler. See
  11568. http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
  11569. http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
  11570. */
  11571. _Bool q = true;
  11572. _Bool *pq = &q;
  11573. int
  11574. main ()
  11575. {
  11576. bool e = &s;
  11577. *pq |= q;
  11578. *pq |= ! q;
  11579. /* Refer to every declared value, to avoid compiler optimizations. */
  11580. return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
  11581. + !m + !n + !o + !p + !q + !pq);
  11582. ;
  11583. return 0;
  11584. }
  11585. _ACEOF
  11586. if ac_fn_c_try_compile "$LINENO"; then :
  11587. ac_cv_header_stdbool_h=yes
  11588. else
  11589. ac_cv_header_stdbool_h=no
  11590. fi
  11591. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11592. fi
  11593. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
  11594. $as_echo "$ac_cv_header_stdbool_h" >&6; }
  11595. ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
  11596. if test "x$ac_cv_type__Bool" = xyes; then :
  11597. cat >>confdefs.h <<_ACEOF
  11598. #define HAVE__BOOL 1
  11599. _ACEOF
  11600. fi
  11601. if test $ac_cv_header_stdbool_h = yes; then
  11602. $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
  11603. fi
  11604. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
  11605. $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
  11606. if ${ac_cv_c_const+:} false; then :
  11607. $as_echo_n "(cached) " >&6
  11608. else
  11609. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11610. /* end confdefs.h. */
  11611. int
  11612. main ()
  11613. {
  11614. #ifndef __cplusplus
  11615. /* Ultrix mips cc rejects this sort of thing. */
  11616. typedef int charset[2];
  11617. const charset cs = { 0, 0 };
  11618. /* SunOS 4.1.1 cc rejects this. */
  11619. char const *const *pcpcc;
  11620. char **ppc;
  11621. /* NEC SVR4.0.2 mips cc rejects this. */
  11622. struct point {int x, y;};
  11623. static struct point const zero = {0,0};
  11624. /* AIX XL C 1.02.0.0 rejects this.
  11625. It does not let you subtract one const X* pointer from another in
  11626. an arm of an if-expression whose if-part is not a constant
  11627. expression */
  11628. const char *g = "string";
  11629. pcpcc = &g + (g ? g-g : 0);
  11630. /* HPUX 7.0 cc rejects these. */
  11631. ++pcpcc;
  11632. ppc = (char**) pcpcc;
  11633. pcpcc = (char const *const *) ppc;
  11634. { /* SCO 3.2v4 cc rejects this sort of thing. */
  11635. char tx;
  11636. char *t = &tx;
  11637. char const *s = 0 ? (char *) 0 : (char const *) 0;
  11638. *t++ = 0;
  11639. if (s) return 0;
  11640. }
  11641. { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
  11642. int x[] = {25, 17};
  11643. const int *foo = &x[0];
  11644. ++foo;
  11645. }
  11646. { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  11647. typedef const int *iptr;
  11648. iptr p = 0;
  11649. ++p;
  11650. }
  11651. { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
  11652. "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  11653. struct s { int j; const int *ap[3]; } bx;
  11654. struct s *b = &bx; b->j = 5;
  11655. }
  11656. { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  11657. const int foo = 10;
  11658. if (!foo) return 0;
  11659. }
  11660. return !cs[0] && !zero.x;
  11661. #endif
  11662. ;
  11663. return 0;
  11664. }
  11665. _ACEOF
  11666. if ac_fn_c_try_compile "$LINENO"; then :
  11667. ac_cv_c_const=yes
  11668. else
  11669. ac_cv_c_const=no
  11670. fi
  11671. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11672. fi
  11673. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
  11674. $as_echo "$ac_cv_c_const" >&6; }
  11675. if test $ac_cv_c_const = no; then
  11676. $as_echo "#define const /**/" >>confdefs.h
  11677. fi
  11678. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
  11679. $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
  11680. if ${ac_cv_type_uid_t+:} false; then :
  11681. $as_echo_n "(cached) " >&6
  11682. else
  11683. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11684. /* end confdefs.h. */
  11685. #include <sys/types.h>
  11686. _ACEOF
  11687. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  11688. $EGREP "uid_t" >/dev/null 2>&1; then :
  11689. ac_cv_type_uid_t=yes
  11690. else
  11691. ac_cv_type_uid_t=no
  11692. fi
  11693. rm -f conftest*
  11694. fi
  11695. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
  11696. $as_echo "$ac_cv_type_uid_t" >&6; }
  11697. if test $ac_cv_type_uid_t = no; then
  11698. $as_echo "#define uid_t int" >>confdefs.h
  11699. $as_echo "#define gid_t int" >>confdefs.h
  11700. fi
  11701. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
  11702. $as_echo_n "checking for inline... " >&6; }
  11703. if ${ac_cv_c_inline+:} false; then :
  11704. $as_echo_n "(cached) " >&6
  11705. else
  11706. ac_cv_c_inline=no
  11707. for ac_kw in inline __inline__ __inline; do
  11708. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11709. /* end confdefs.h. */
  11710. #ifndef __cplusplus
  11711. typedef int foo_t;
  11712. static $ac_kw foo_t static_foo () {return 0; }
  11713. $ac_kw foo_t foo () {return 0; }
  11714. #endif
  11715. _ACEOF
  11716. if ac_fn_c_try_compile "$LINENO"; then :
  11717. ac_cv_c_inline=$ac_kw
  11718. fi
  11719. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11720. test "$ac_cv_c_inline" != no && break
  11721. done
  11722. fi
  11723. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
  11724. $as_echo "$ac_cv_c_inline" >&6; }
  11725. case $ac_cv_c_inline in
  11726. inline | yes) ;;
  11727. *)
  11728. case $ac_cv_c_inline in
  11729. no) ac_val=;;
  11730. *) ac_val=$ac_cv_c_inline;;
  11731. esac
  11732. cat >>confdefs.h <<_ACEOF
  11733. #ifndef __cplusplus
  11734. #define inline $ac_val
  11735. #endif
  11736. _ACEOF
  11737. ;;
  11738. esac
  11739. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double with more range or precision than double" >&5
  11740. $as_echo_n "checking for long double with more range or precision than double... " >&6; }
  11741. if ${ac_cv_type_long_double_wider+:} false; then :
  11742. $as_echo_n "(cached) " >&6
  11743. else
  11744. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11745. /* end confdefs.h. */
  11746. #include <float.h>
  11747. long double const a[] =
  11748. {
  11749. 0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON,
  11750. LDBL_MIN, LDBL_MAX, LDBL_EPSILON
  11751. };
  11752. long double
  11753. f (long double x)
  11754. {
  11755. return ((x + (unsigned long int) 10) * (-1 / x) + a[0]
  11756. + (x ? f (x) : 'c'));
  11757. }
  11758. int
  11759. main ()
  11760. {
  11761. static int test_array [1 - 2 * !((0 < ((DBL_MAX_EXP < LDBL_MAX_EXP)
  11762. + (DBL_MANT_DIG < LDBL_MANT_DIG)
  11763. - (LDBL_MAX_EXP < DBL_MAX_EXP)
  11764. - (LDBL_MANT_DIG < DBL_MANT_DIG)))
  11765. && (int) LDBL_EPSILON == 0
  11766. )];
  11767. test_array [0] = 0;
  11768. return test_array [0];
  11769. ;
  11770. return 0;
  11771. }
  11772. _ACEOF
  11773. if ac_fn_c_try_compile "$LINENO"; then :
  11774. ac_cv_type_long_double_wider=yes
  11775. else
  11776. ac_cv_type_long_double_wider=no
  11777. fi
  11778. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11779. fi
  11780. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double_wider" >&5
  11781. $as_echo "$ac_cv_type_long_double_wider" >&6; }
  11782. if test $ac_cv_type_long_double_wider = yes; then
  11783. $as_echo "#define HAVE_LONG_DOUBLE_WIDER 1" >>confdefs.h
  11784. fi
  11785. ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
  11786. if test "x$ac_cv_type_mode_t" = xyes; then :
  11787. else
  11788. cat >>confdefs.h <<_ACEOF
  11789. #define mode_t int
  11790. _ACEOF
  11791. fi
  11792. ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
  11793. if test "x$ac_cv_type_off_t" = xyes; then :
  11794. else
  11795. cat >>confdefs.h <<_ACEOF
  11796. #define off_t long int
  11797. _ACEOF
  11798. fi
  11799. ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
  11800. if test "x$ac_cv_type_pid_t" = xyes; then :
  11801. else
  11802. cat >>confdefs.h <<_ACEOF
  11803. #define pid_t int
  11804. _ACEOF
  11805. fi
  11806. ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
  11807. if test "x$ac_cv_type_size_t" = xyes; then :
  11808. else
  11809. cat >>confdefs.h <<_ACEOF
  11810. #define size_t unsigned int
  11811. _ACEOF
  11812. fi
  11813. ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
  11814. if test "x$ac_cv_member_struct_stat_st_blksize" = xyes; then :
  11815. cat >>confdefs.h <<_ACEOF
  11816. #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
  11817. _ACEOF
  11818. fi
  11819. ac_fn_c_check_member "$LINENO" "struct ucred" "uid" "ac_cv_member_struct_ucred_uid" "#include <sys/types.h>
  11820. #include <sys/socket.h>
  11821. "
  11822. if test "x$ac_cv_member_struct_ucred_uid" = xyes; then :
  11823. cat >>confdefs.h <<_ACEOF
  11824. #define HAVE_STRUCT_UCRED_UID 1
  11825. _ACEOF
  11826. fi
  11827. ac_fn_c_check_member "$LINENO" "struct ucred" "cr_uid" "ac_cv_member_struct_ucred_cr_uid" "#include <sys/types.h>
  11828. #include <sys/socket.h>
  11829. "
  11830. if test "x$ac_cv_member_struct_ucred_cr_uid" = xyes; then :
  11831. cat >>confdefs.h <<_ACEOF
  11832. #define HAVE_STRUCT_UCRED_CR_UID 1
  11833. _ACEOF
  11834. fi
  11835. ac_fn_c_check_member "$LINENO" "struct sockpeercred" "uid" "ac_cv_member_struct_sockpeercred_uid" "#include <sys/types.h>
  11836. #include <sys/socket.h>
  11837. "
  11838. if test "x$ac_cv_member_struct_sockpeercred_uid" = xyes; then :
  11839. cat >>confdefs.h <<_ACEOF
  11840. #define HAVE_STRUCT_SOCKPEERCRED_UID 1
  11841. _ACEOF
  11842. fi
  11843. 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>
  11844. "
  11845. if test "x$ac_cv_member_struct_ifreq_ifr_ifru_ifru_hwaddr" = xyes; then :
  11846. cat >>confdefs.h <<_ACEOF
  11847. #define HAVE_STRUCT_IFREQ_IFR_IFRU_IFRU_HWADDR 1
  11848. _ACEOF
  11849. fi
  11850. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
  11851. $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
  11852. if ${ac_cv_header_time+:} false; then :
  11853. $as_echo_n "(cached) " >&6
  11854. else
  11855. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11856. /* end confdefs.h. */
  11857. #include <sys/types.h>
  11858. #include <sys/time.h>
  11859. #include <time.h>
  11860. int
  11861. main ()
  11862. {
  11863. if ((struct tm *) 0)
  11864. return 0;
  11865. ;
  11866. return 0;
  11867. }
  11868. _ACEOF
  11869. if ac_fn_c_try_compile "$LINENO"; then :
  11870. ac_cv_header_time=yes
  11871. else
  11872. ac_cv_header_time=no
  11873. fi
  11874. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11875. fi
  11876. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
  11877. $as_echo "$ac_cv_header_time" >&6; }
  11878. if test $ac_cv_header_time = yes; then
  11879. $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
  11880. fi
  11881. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
  11882. $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
  11883. if ${ac_cv_struct_tm+:} false; then :
  11884. $as_echo_n "(cached) " >&6
  11885. else
  11886. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11887. /* end confdefs.h. */
  11888. #include <sys/types.h>
  11889. #include <time.h>
  11890. int
  11891. main ()
  11892. {
  11893. struct tm tm;
  11894. int *p = &tm.tm_sec;
  11895. return !p;
  11896. ;
  11897. return 0;
  11898. }
  11899. _ACEOF
  11900. if ac_fn_c_try_compile "$LINENO"; then :
  11901. ac_cv_struct_tm=time.h
  11902. else
  11903. ac_cv_struct_tm=sys/time.h
  11904. fi
  11905. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11906. fi
  11907. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
  11908. $as_echo "$ac_cv_struct_tm" >&6; }
  11909. if test $ac_cv_struct_tm = sys/time.h; then
  11910. $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
  11911. fi
  11912. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
  11913. $as_echo_n "checking for working volatile... " >&6; }
  11914. if ${ac_cv_c_volatile+:} false; then :
  11915. $as_echo_n "(cached) " >&6
  11916. else
  11917. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11918. /* end confdefs.h. */
  11919. int
  11920. main ()
  11921. {
  11922. volatile int x;
  11923. int * volatile y = (int *) 0;
  11924. return !x && !y;
  11925. ;
  11926. return 0;
  11927. }
  11928. _ACEOF
  11929. if ac_fn_c_try_compile "$LINENO"; then :
  11930. ac_cv_c_volatile=yes
  11931. else
  11932. ac_cv_c_volatile=no
  11933. fi
  11934. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  11935. fi
  11936. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
  11937. $as_echo "$ac_cv_c_volatile" >&6; }
  11938. if test $ac_cv_c_volatile = no; then
  11939. $as_echo "#define volatile /**/" >>confdefs.h
  11940. fi
  11941. ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
  11942. if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
  11943. cat >>confdefs.h <<_ACEOF
  11944. #define HAVE_PTRDIFF_T 1
  11945. _ACEOF
  11946. fi
  11947. stat_nsec_found=no
  11948. ac_fn_c_check_member "$LINENO" "struct stat" "st_mtim" "ac_cv_member_struct_stat_st_mtim" "#include <sys/stat.h>
  11949. "
  11950. if test "x$ac_cv_member_struct_stat_st_mtim" = xyes; then :
  11951. cat >>confdefs.h <<_ACEOF
  11952. #define HAVE_STRUCT_STAT_ST_MTIM 1
  11953. _ACEOF
  11954. stat_nsec_found=yes
  11955. fi
  11956. ac_fn_c_check_member "$LINENO" "struct stat" "st_mtimensec" "ac_cv_member_struct_stat_st_mtimensec" "#include <sys/stat.h>
  11957. "
  11958. if test "x$ac_cv_member_struct_stat_st_mtimensec" = xyes; then :
  11959. cat >>confdefs.h <<_ACEOF
  11960. #define HAVE_STRUCT_STAT_ST_MTIMENSEC 1
  11961. _ACEOF
  11962. stat_nsec_found=yes
  11963. fi
  11964. ac_fn_c_check_member "$LINENO" "struct stat" "st_mtimespec" "ac_cv_member_struct_stat_st_mtimespec" "#include <sys/stat.h>
  11965. "
  11966. if test "x$ac_cv_member_struct_stat_st_mtimespec" = xyes; then :
  11967. cat >>confdefs.h <<_ACEOF
  11968. #define HAVE_STRUCT_STAT_ST_MTIMESPEC 1
  11969. _ACEOF
  11970. stat_nsec_found=yes
  11971. fi
  11972. if test "${stat_nsec_found}" != yes; then
  11973. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot determine nanosecond field of struct stat" >&5
  11974. $as_echo "$as_me: WARNING: Cannot determine nanosecond field of struct stat" >&2;}
  11975. fi
  11976. # Checks for library functions.
  11977. for ac_header in unistd.h
  11978. do :
  11979. ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
  11980. if test "x$ac_cv_header_unistd_h" = xyes; then :
  11981. cat >>confdefs.h <<_ACEOF
  11982. #define HAVE_UNISTD_H 1
  11983. _ACEOF
  11984. fi
  11985. done
  11986. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
  11987. $as_echo_n "checking for working chown... " >&6; }
  11988. if ${ac_cv_func_chown_works+:} false; then :
  11989. $as_echo_n "(cached) " >&6
  11990. else
  11991. if test "$cross_compiling" = yes; then :
  11992. ac_cv_func_chown_works=no
  11993. else
  11994. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  11995. /* end confdefs.h. */
  11996. $ac_includes_default
  11997. #include <fcntl.h>
  11998. int
  11999. main ()
  12000. {
  12001. char *f = "conftest.chown";
  12002. struct stat before, after;
  12003. if (creat (f, 0600) < 0)
  12004. return 1;
  12005. if (stat (f, &before) < 0)
  12006. return 1;
  12007. if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
  12008. return 1;
  12009. if (stat (f, &after) < 0)
  12010. return 1;
  12011. return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
  12012. ;
  12013. return 0;
  12014. }
  12015. _ACEOF
  12016. if ac_fn_c_try_run "$LINENO"; then :
  12017. ac_cv_func_chown_works=yes
  12018. else
  12019. ac_cv_func_chown_works=no
  12020. fi
  12021. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12022. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12023. fi
  12024. rm -f conftest.chown
  12025. fi
  12026. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
  12027. $as_echo "$ac_cv_func_chown_works" >&6; }
  12028. if test $ac_cv_func_chown_works = yes; then
  12029. $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
  12030. fi
  12031. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether closedir returns void" >&5
  12032. $as_echo_n "checking whether closedir returns void... " >&6; }
  12033. if ${ac_cv_func_closedir_void+:} false; then :
  12034. $as_echo_n "(cached) " >&6
  12035. else
  12036. if test "$cross_compiling" = yes; then :
  12037. ac_cv_func_closedir_void=yes
  12038. else
  12039. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12040. /* end confdefs.h. */
  12041. $ac_includes_default
  12042. #include <$ac_header_dirent>
  12043. #ifndef __cplusplus
  12044. int closedir ();
  12045. #endif
  12046. int
  12047. main ()
  12048. {
  12049. return closedir (opendir (".")) != 0;
  12050. ;
  12051. return 0;
  12052. }
  12053. _ACEOF
  12054. if ac_fn_c_try_run "$LINENO"; then :
  12055. ac_cv_func_closedir_void=no
  12056. else
  12057. ac_cv_func_closedir_void=yes
  12058. fi
  12059. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12060. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12061. fi
  12062. fi
  12063. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_closedir_void" >&5
  12064. $as_echo "$ac_cv_func_closedir_void" >&6; }
  12065. if test $ac_cv_func_closedir_void = yes; then
  12066. $as_echo "#define CLOSEDIR_VOID 1" >>confdefs.h
  12067. fi
  12068. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
  12069. $as_echo_n "checking for error_at_line... " >&6; }
  12070. if ${ac_cv_lib_error_at_line+:} false; then :
  12071. $as_echo_n "(cached) " >&6
  12072. else
  12073. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12074. /* end confdefs.h. */
  12075. #include <error.h>
  12076. int
  12077. main ()
  12078. {
  12079. error_at_line (0, 0, "", 0, "an error occurred");
  12080. ;
  12081. return 0;
  12082. }
  12083. _ACEOF
  12084. if ac_fn_c_try_link "$LINENO"; then :
  12085. ac_cv_lib_error_at_line=yes
  12086. else
  12087. ac_cv_lib_error_at_line=no
  12088. fi
  12089. rm -f core conftest.err conftest.$ac_objext \
  12090. conftest$ac_exeext conftest.$ac_ext
  12091. fi
  12092. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
  12093. $as_echo "$ac_cv_lib_error_at_line" >&6; }
  12094. if test $ac_cv_lib_error_at_line = no; then
  12095. case " $LIBOBJS " in
  12096. *" error.$ac_objext "* ) ;;
  12097. *) LIBOBJS="$LIBOBJS error.$ac_objext"
  12098. ;;
  12099. esac
  12100. fi
  12101. for ac_header in vfork.h
  12102. do :
  12103. ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
  12104. if test "x$ac_cv_header_vfork_h" = xyes; then :
  12105. cat >>confdefs.h <<_ACEOF
  12106. #define HAVE_VFORK_H 1
  12107. _ACEOF
  12108. fi
  12109. done
  12110. for ac_func in fork vfork
  12111. do :
  12112. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  12113. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  12114. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  12115. cat >>confdefs.h <<_ACEOF
  12116. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  12117. _ACEOF
  12118. fi
  12119. done
  12120. if test "x$ac_cv_func_fork" = xyes; then
  12121. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
  12122. $as_echo_n "checking for working fork... " >&6; }
  12123. if ${ac_cv_func_fork_works+:} false; then :
  12124. $as_echo_n "(cached) " >&6
  12125. else
  12126. if test "$cross_compiling" = yes; then :
  12127. ac_cv_func_fork_works=cross
  12128. else
  12129. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12130. /* end confdefs.h. */
  12131. $ac_includes_default
  12132. int
  12133. main ()
  12134. {
  12135. /* By Ruediger Kuhlmann. */
  12136. return fork () < 0;
  12137. ;
  12138. return 0;
  12139. }
  12140. _ACEOF
  12141. if ac_fn_c_try_run "$LINENO"; then :
  12142. ac_cv_func_fork_works=yes
  12143. else
  12144. ac_cv_func_fork_works=no
  12145. fi
  12146. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12147. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12148. fi
  12149. fi
  12150. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
  12151. $as_echo "$ac_cv_func_fork_works" >&6; }
  12152. else
  12153. ac_cv_func_fork_works=$ac_cv_func_fork
  12154. fi
  12155. if test "x$ac_cv_func_fork_works" = xcross; then
  12156. case $host in
  12157. *-*-amigaos* | *-*-msdosdjgpp* | *-*-uclinux* )
  12158. # Override, as these systems have only a dummy fork() stub
  12159. ac_cv_func_fork_works=no
  12160. ;;
  12161. *)
  12162. ac_cv_func_fork_works=yes
  12163. ;;
  12164. esac
  12165. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
  12166. $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
  12167. fi
  12168. ac_cv_func_vfork_works=$ac_cv_func_vfork
  12169. if test "x$ac_cv_func_vfork" = xyes; then
  12170. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
  12171. $as_echo_n "checking for working vfork... " >&6; }
  12172. if ${ac_cv_func_vfork_works+:} false; then :
  12173. $as_echo_n "(cached) " >&6
  12174. else
  12175. if test "$cross_compiling" = yes; then :
  12176. ac_cv_func_vfork_works=cross
  12177. else
  12178. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12179. /* end confdefs.h. */
  12180. /* Thanks to Paul Eggert for this test. */
  12181. $ac_includes_default
  12182. #include <sys/wait.h>
  12183. #ifdef HAVE_VFORK_H
  12184. # include <vfork.h>
  12185. #endif
  12186. /* On some sparc systems, changes by the child to local and incoming
  12187. argument registers are propagated back to the parent. The compiler
  12188. is told about this with #include <vfork.h>, but some compilers
  12189. (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
  12190. static variable whose address is put into a register that is
  12191. clobbered by the vfork. */
  12192. static void
  12193. #ifdef __cplusplus
  12194. sparc_address_test (int arg)
  12195. # else
  12196. sparc_address_test (arg) int arg;
  12197. #endif
  12198. {
  12199. static pid_t child;
  12200. if (!child) {
  12201. child = vfork ();
  12202. if (child < 0) {
  12203. perror ("vfork");
  12204. _exit(2);
  12205. }
  12206. if (!child) {
  12207. arg = getpid();
  12208. write(-1, "", 0);
  12209. _exit (arg);
  12210. }
  12211. }
  12212. }
  12213. int
  12214. main ()
  12215. {
  12216. pid_t parent = getpid ();
  12217. pid_t child;
  12218. sparc_address_test (0);
  12219. child = vfork ();
  12220. if (child == 0) {
  12221. /* Here is another test for sparc vfork register problems. This
  12222. test uses lots of local variables, at least as many local
  12223. variables as main has allocated so far including compiler
  12224. temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
  12225. 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
  12226. reuse the register of parent for one of the local variables,
  12227. since it will think that parent can't possibly be used any more
  12228. in this routine. Assigning to the local variable will thus
  12229. munge parent in the parent process. */
  12230. pid_t
  12231. p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
  12232. p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
  12233. /* Convince the compiler that p..p7 are live; otherwise, it might
  12234. use the same hardware register for all 8 local variables. */
  12235. if (p != p1 || p != p2 || p != p3 || p != p4
  12236. || p != p5 || p != p6 || p != p7)
  12237. _exit(1);
  12238. /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
  12239. from child file descriptors. If the child closes a descriptor
  12240. before it execs or exits, this munges the parent's descriptor
  12241. as well. Test for this by closing stdout in the child. */
  12242. _exit(close(fileno(stdout)) != 0);
  12243. } else {
  12244. int status;
  12245. struct stat st;
  12246. while (wait(&status) != child)
  12247. ;
  12248. return (
  12249. /* Was there some problem with vforking? */
  12250. child < 0
  12251. /* Did the child fail? (This shouldn't happen.) */
  12252. || status
  12253. /* Did the vfork/compiler bug occur? */
  12254. || parent != getpid()
  12255. /* Did the file descriptor bug occur? */
  12256. || fstat(fileno(stdout), &st) != 0
  12257. );
  12258. }
  12259. }
  12260. _ACEOF
  12261. if ac_fn_c_try_run "$LINENO"; then :
  12262. ac_cv_func_vfork_works=yes
  12263. else
  12264. ac_cv_func_vfork_works=no
  12265. fi
  12266. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12267. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12268. fi
  12269. fi
  12270. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
  12271. $as_echo "$ac_cv_func_vfork_works" >&6; }
  12272. fi;
  12273. if test "x$ac_cv_func_fork_works" = xcross; then
  12274. ac_cv_func_vfork_works=$ac_cv_func_vfork
  12275. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
  12276. $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
  12277. fi
  12278. if test "x$ac_cv_func_vfork_works" = xyes; then
  12279. $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
  12280. else
  12281. $as_echo "#define vfork fork" >>confdefs.h
  12282. fi
  12283. if test "x$ac_cv_func_fork_works" = xyes; then
  12284. $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
  12285. PBX_WORKING_FORK=1
  12286. fi
  12287. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
  12288. $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
  12289. if ${ac_cv_sys_largefile_source+:} false; then :
  12290. $as_echo_n "(cached) " >&6
  12291. else
  12292. while :; do
  12293. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12294. /* end confdefs.h. */
  12295. #include <sys/types.h> /* for off_t */
  12296. #include <stdio.h>
  12297. int
  12298. main ()
  12299. {
  12300. int (*fp) (FILE *, off_t, int) = fseeko;
  12301. return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
  12302. ;
  12303. return 0;
  12304. }
  12305. _ACEOF
  12306. if ac_fn_c_try_link "$LINENO"; then :
  12307. ac_cv_sys_largefile_source=no; break
  12308. fi
  12309. rm -f core conftest.err conftest.$ac_objext \
  12310. conftest$ac_exeext conftest.$ac_ext
  12311. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12312. /* end confdefs.h. */
  12313. #define _LARGEFILE_SOURCE 1
  12314. #include <sys/types.h> /* for off_t */
  12315. #include <stdio.h>
  12316. int
  12317. main ()
  12318. {
  12319. int (*fp) (FILE *, off_t, int) = fseeko;
  12320. return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
  12321. ;
  12322. return 0;
  12323. }
  12324. _ACEOF
  12325. if ac_fn_c_try_link "$LINENO"; then :
  12326. ac_cv_sys_largefile_source=1; break
  12327. fi
  12328. rm -f core conftest.err conftest.$ac_objext \
  12329. conftest$ac_exeext conftest.$ac_ext
  12330. ac_cv_sys_largefile_source=unknown
  12331. break
  12332. done
  12333. fi
  12334. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
  12335. $as_echo "$ac_cv_sys_largefile_source" >&6; }
  12336. case $ac_cv_sys_largefile_source in #(
  12337. no | unknown) ;;
  12338. *)
  12339. cat >>confdefs.h <<_ACEOF
  12340. #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
  12341. _ACEOF
  12342. ;;
  12343. esac
  12344. rm -rf conftest*
  12345. # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
  12346. # in glibc 2.1.3, but that breaks too many other things.
  12347. # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
  12348. if test $ac_cv_sys_largefile_source != unknown; then
  12349. $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
  12350. fi
  12351. if test $ac_cv_c_compiler_gnu = yes; then
  12352. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
  12353. $as_echo_n "checking whether $CC needs -traditional... " >&6; }
  12354. if ${ac_cv_prog_gcc_traditional+:} false; then :
  12355. $as_echo_n "(cached) " >&6
  12356. else
  12357. ac_pattern="Autoconf.*'x'"
  12358. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12359. /* end confdefs.h. */
  12360. #include <sgtty.h>
  12361. Autoconf TIOCGETP
  12362. _ACEOF
  12363. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  12364. $EGREP "$ac_pattern" >/dev/null 2>&1; then :
  12365. ac_cv_prog_gcc_traditional=yes
  12366. else
  12367. ac_cv_prog_gcc_traditional=no
  12368. fi
  12369. rm -f conftest*
  12370. if test $ac_cv_prog_gcc_traditional = no; then
  12371. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12372. /* end confdefs.h. */
  12373. #include <termio.h>
  12374. Autoconf TCGETA
  12375. _ACEOF
  12376. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  12377. $EGREP "$ac_pattern" >/dev/null 2>&1; then :
  12378. ac_cv_prog_gcc_traditional=yes
  12379. fi
  12380. rm -f conftest*
  12381. fi
  12382. fi
  12383. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
  12384. $as_echo "$ac_cv_prog_gcc_traditional" >&6; }
  12385. if test $ac_cv_prog_gcc_traditional = yes; then
  12386. CC="$CC -traditional"
  12387. fi
  12388. fi
  12389. # XXX: these are commented out until we determine whether it matters if our malloc()
  12390. # acts exactly like glibc's or not
  12391. # AC_FUNC_MALLOC
  12392. # AC_FUNC_REALLOC
  12393. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working memcmp" >&5
  12394. $as_echo_n "checking for working memcmp... " >&6; }
  12395. if ${ac_cv_func_memcmp_working+:} false; then :
  12396. $as_echo_n "(cached) " >&6
  12397. else
  12398. if test "$cross_compiling" = yes; then :
  12399. ac_cv_func_memcmp_working=no
  12400. else
  12401. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12402. /* end confdefs.h. */
  12403. $ac_includes_default
  12404. int
  12405. main ()
  12406. {
  12407. /* Some versions of memcmp are not 8-bit clean. */
  12408. char c0 = '\100', c1 = '\200', c2 = '\201';
  12409. if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
  12410. return 1;
  12411. /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
  12412. or more and with at least one buffer not starting on a 4-byte boundary.
  12413. William Lewis provided this test program. */
  12414. {
  12415. char foo[21];
  12416. char bar[21];
  12417. int i;
  12418. for (i = 0; i < 4; i++)
  12419. {
  12420. char *a = foo + i;
  12421. char *b = bar + i;
  12422. strcpy (a, "--------01111111");
  12423. strcpy (b, "--------10000000");
  12424. if (memcmp (a, b, 16) >= 0)
  12425. return 1;
  12426. }
  12427. return 0;
  12428. }
  12429. ;
  12430. return 0;
  12431. }
  12432. _ACEOF
  12433. if ac_fn_c_try_run "$LINENO"; then :
  12434. ac_cv_func_memcmp_working=yes
  12435. else
  12436. ac_cv_func_memcmp_working=no
  12437. fi
  12438. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12439. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12440. fi
  12441. fi
  12442. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_memcmp_working" >&5
  12443. $as_echo "$ac_cv_func_memcmp_working" >&6; }
  12444. test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
  12445. *" memcmp.$ac_objext "* ) ;;
  12446. *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
  12447. ;;
  12448. esac
  12449. for ac_header in $ac_header_list
  12450. do :
  12451. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  12452. ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
  12453. "
  12454. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  12455. cat >>confdefs.h <<_ACEOF
  12456. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  12457. _ACEOF
  12458. fi
  12459. done
  12460. for ac_func in getpagesize
  12461. do :
  12462. ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
  12463. if test "x$ac_cv_func_getpagesize" = xyes; then :
  12464. cat >>confdefs.h <<_ACEOF
  12465. #define HAVE_GETPAGESIZE 1
  12466. _ACEOF
  12467. fi
  12468. done
  12469. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
  12470. $as_echo_n "checking for working mmap... " >&6; }
  12471. if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
  12472. $as_echo_n "(cached) " >&6
  12473. else
  12474. if test "$cross_compiling" = yes; then :
  12475. ac_cv_func_mmap_fixed_mapped=no
  12476. else
  12477. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12478. /* end confdefs.h. */
  12479. $ac_includes_default
  12480. /* malloc might have been renamed as rpl_malloc. */
  12481. #undef malloc
  12482. /* Thanks to Mike Haertel and Jim Avera for this test.
  12483. Here is a matrix of mmap possibilities:
  12484. mmap private not fixed
  12485. mmap private fixed at somewhere currently unmapped
  12486. mmap private fixed at somewhere already mapped
  12487. mmap shared not fixed
  12488. mmap shared fixed at somewhere currently unmapped
  12489. mmap shared fixed at somewhere already mapped
  12490. For private mappings, we should verify that changes cannot be read()
  12491. back from the file, nor mmap's back from the file at a different
  12492. address. (There have been systems where private was not correctly
  12493. implemented like the infamous i386 svr4.0, and systems where the
  12494. VM page cache was not coherent with the file system buffer cache
  12495. like early versions of FreeBSD and possibly contemporary NetBSD.)
  12496. For shared mappings, we should conversely verify that changes get
  12497. propagated back to all the places they're supposed to be.
  12498. Grep wants private fixed already mapped.
  12499. The main things grep needs to know about mmap are:
  12500. * does it exist and is it safe to write into the mmap'd area
  12501. * how to use it (BSD variants) */
  12502. #include <fcntl.h>
  12503. #include <sys/mman.h>
  12504. #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
  12505. char *malloc ();
  12506. #endif
  12507. /* This mess was copied from the GNU getpagesize.h. */
  12508. #ifndef HAVE_GETPAGESIZE
  12509. # ifdef _SC_PAGESIZE
  12510. # define getpagesize() sysconf(_SC_PAGESIZE)
  12511. # else /* no _SC_PAGESIZE */
  12512. # ifdef HAVE_SYS_PARAM_H
  12513. # include <sys/param.h>
  12514. # ifdef EXEC_PAGESIZE
  12515. # define getpagesize() EXEC_PAGESIZE
  12516. # else /* no EXEC_PAGESIZE */
  12517. # ifdef NBPG
  12518. # define getpagesize() NBPG * CLSIZE
  12519. # ifndef CLSIZE
  12520. # define CLSIZE 1
  12521. # endif /* no CLSIZE */
  12522. # else /* no NBPG */
  12523. # ifdef NBPC
  12524. # define getpagesize() NBPC
  12525. # else /* no NBPC */
  12526. # ifdef PAGESIZE
  12527. # define getpagesize() PAGESIZE
  12528. # endif /* PAGESIZE */
  12529. # endif /* no NBPC */
  12530. # endif /* no NBPG */
  12531. # endif /* no EXEC_PAGESIZE */
  12532. # else /* no HAVE_SYS_PARAM_H */
  12533. # define getpagesize() 8192 /* punt totally */
  12534. # endif /* no HAVE_SYS_PARAM_H */
  12535. # endif /* no _SC_PAGESIZE */
  12536. #endif /* no HAVE_GETPAGESIZE */
  12537. int
  12538. main ()
  12539. {
  12540. char *data, *data2, *data3;
  12541. const char *cdata2;
  12542. int i, pagesize;
  12543. int fd, fd2;
  12544. pagesize = getpagesize ();
  12545. /* First, make a file with some known garbage in it. */
  12546. data = (char *) malloc (pagesize);
  12547. if (!data)
  12548. return 1;
  12549. for (i = 0; i < pagesize; ++i)
  12550. *(data + i) = rand ();
  12551. umask (0);
  12552. fd = creat ("conftest.mmap", 0600);
  12553. if (fd < 0)
  12554. return 2;
  12555. if (write (fd, data, pagesize) != pagesize)
  12556. return 3;
  12557. close (fd);
  12558. /* Next, check that the tail of a page is zero-filled. File must have
  12559. non-zero length, otherwise we risk SIGBUS for entire page. */
  12560. fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
  12561. if (fd2 < 0)
  12562. return 4;
  12563. cdata2 = "";
  12564. if (write (fd2, cdata2, 1) != 1)
  12565. return 5;
  12566. data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
  12567. if (data2 == MAP_FAILED)
  12568. return 6;
  12569. for (i = 0; i < pagesize; ++i)
  12570. if (*(data2 + i))
  12571. return 7;
  12572. close (fd2);
  12573. if (munmap (data2, pagesize))
  12574. return 8;
  12575. /* Next, try to mmap the file at a fixed address which already has
  12576. something else allocated at it. If we can, also make sure that
  12577. we see the same garbage. */
  12578. fd = open ("conftest.mmap", O_RDWR);
  12579. if (fd < 0)
  12580. return 9;
  12581. if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
  12582. MAP_PRIVATE | MAP_FIXED, fd, 0L))
  12583. return 10;
  12584. for (i = 0; i < pagesize; ++i)
  12585. if (*(data + i) != *(data2 + i))
  12586. return 11;
  12587. /* Finally, make sure that changes to the mapped area do not
  12588. percolate back to the file as seen by read(). (This is a bug on
  12589. some variants of i386 svr4.0.) */
  12590. for (i = 0; i < pagesize; ++i)
  12591. *(data2 + i) = *(data2 + i) + 1;
  12592. data3 = (char *) malloc (pagesize);
  12593. if (!data3)
  12594. return 12;
  12595. if (read (fd, data3, pagesize) != pagesize)
  12596. return 13;
  12597. for (i = 0; i < pagesize; ++i)
  12598. if (*(data + i) != *(data3 + i))
  12599. return 14;
  12600. close (fd);
  12601. return 0;
  12602. }
  12603. _ACEOF
  12604. if ac_fn_c_try_run "$LINENO"; then :
  12605. ac_cv_func_mmap_fixed_mapped=yes
  12606. else
  12607. ac_cv_func_mmap_fixed_mapped=no
  12608. fi
  12609. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12610. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12611. fi
  12612. fi
  12613. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
  12614. $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
  12615. if test $ac_cv_func_mmap_fixed_mapped = yes; then
  12616. $as_echo "#define HAVE_MMAP 1" >>confdefs.h
  12617. fi
  12618. rm -f conftest.mmap conftest.txt
  12619. for ac_header in sys/select.h sys/socket.h
  12620. do :
  12621. as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
  12622. ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
  12623. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  12624. cat >>confdefs.h <<_ACEOF
  12625. #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
  12626. _ACEOF
  12627. fi
  12628. done
  12629. { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of arguments for select" >&5
  12630. $as_echo_n "checking types of arguments for select... " >&6; }
  12631. if ${ac_cv_func_select_args+:} false; then :
  12632. $as_echo_n "(cached) " >&6
  12633. else
  12634. for ac_arg234 in 'fd_set *' 'int *' 'void *'; do
  12635. for ac_arg1 in 'int' 'size_t' 'unsigned long int' 'unsigned int'; do
  12636. for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do
  12637. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12638. /* end confdefs.h. */
  12639. $ac_includes_default
  12640. #ifdef HAVE_SYS_SELECT_H
  12641. # include <sys/select.h>
  12642. #endif
  12643. #ifdef HAVE_SYS_SOCKET_H
  12644. # include <sys/socket.h>
  12645. #endif
  12646. int
  12647. main ()
  12648. {
  12649. extern int select ($ac_arg1,
  12650. $ac_arg234, $ac_arg234, $ac_arg234,
  12651. $ac_arg5);
  12652. ;
  12653. return 0;
  12654. }
  12655. _ACEOF
  12656. if ac_fn_c_try_compile "$LINENO"; then :
  12657. ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3
  12658. fi
  12659. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  12660. done
  12661. done
  12662. done
  12663. # Provide a safe default value.
  12664. : "${ac_cv_func_select_args=int,int *,struct timeval *}"
  12665. fi
  12666. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_select_args" >&5
  12667. $as_echo "$ac_cv_func_select_args" >&6; }
  12668. ac_save_IFS=$IFS; IFS=','
  12669. set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'`
  12670. IFS=$ac_save_IFS
  12671. shift
  12672. cat >>confdefs.h <<_ACEOF
  12673. #define SELECT_TYPE_ARG1 $1
  12674. _ACEOF
  12675. cat >>confdefs.h <<_ACEOF
  12676. #define SELECT_TYPE_ARG234 ($2)
  12677. _ACEOF
  12678. cat >>confdefs.h <<_ACEOF
  12679. #define SELECT_TYPE_ARG5 ($3)
  12680. _ACEOF
  12681. rm -f conftest*
  12682. if ${ac_cv_func_setvbuf_reversed+:} false; then :
  12683. $as_echo_n "(cached) " >&6
  12684. else
  12685. ac_cv_func_setvbuf_reversed=no
  12686. fi
  12687. { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
  12688. $as_echo_n "checking return type of signal handlers... " >&6; }
  12689. if ${ac_cv_type_signal+:} false; then :
  12690. $as_echo_n "(cached) " >&6
  12691. else
  12692. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12693. /* end confdefs.h. */
  12694. #include <sys/types.h>
  12695. #include <signal.h>
  12696. int
  12697. main ()
  12698. {
  12699. return *(signal (0, 0)) (0) == 1;
  12700. ;
  12701. return 0;
  12702. }
  12703. _ACEOF
  12704. if ac_fn_c_try_compile "$LINENO"; then :
  12705. ac_cv_type_signal=int
  12706. else
  12707. ac_cv_type_signal=void
  12708. fi
  12709. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  12710. fi
  12711. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
  12712. $as_echo "$ac_cv_type_signal" >&6; }
  12713. cat >>confdefs.h <<_ACEOF
  12714. #define RETSIGTYPE $ac_cv_type_signal
  12715. _ACEOF
  12716. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
  12717. $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
  12718. if ${ac_cv_func_lstat_dereferences_slashed_symlink+:} false; then :
  12719. $as_echo_n "(cached) " >&6
  12720. else
  12721. rm -f conftest.sym conftest.file
  12722. echo >conftest.file
  12723. if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
  12724. if test "$cross_compiling" = yes; then :
  12725. ac_cv_func_lstat_dereferences_slashed_symlink=no
  12726. else
  12727. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12728. /* end confdefs.h. */
  12729. $ac_includes_default
  12730. int
  12731. main ()
  12732. {
  12733. struct stat sbuf;
  12734. /* Linux will dereference the symlink and fail, as required by POSIX.
  12735. That is better in the sense that it means we will not
  12736. have to compile and use the lstat wrapper. */
  12737. return lstat ("conftest.sym/", &sbuf) == 0;
  12738. ;
  12739. return 0;
  12740. }
  12741. _ACEOF
  12742. if ac_fn_c_try_run "$LINENO"; then :
  12743. ac_cv_func_lstat_dereferences_slashed_symlink=yes
  12744. else
  12745. ac_cv_func_lstat_dereferences_slashed_symlink=no
  12746. fi
  12747. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12748. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12749. fi
  12750. else
  12751. # If the `ln -s' command failed, then we probably don't even
  12752. # have an lstat function.
  12753. ac_cv_func_lstat_dereferences_slashed_symlink=no
  12754. fi
  12755. rm -f conftest.sym conftest.file
  12756. fi
  12757. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5
  12758. $as_echo "$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; }
  12759. test $ac_cv_func_lstat_dereferences_slashed_symlink = yes &&
  12760. cat >>confdefs.h <<_ACEOF
  12761. #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
  12762. _ACEOF
  12763. if test "x$ac_cv_func_lstat_dereferences_slashed_symlink" = xno; then
  12764. case " $LIBOBJS " in
  12765. *" lstat.$ac_objext "* ) ;;
  12766. *) LIBOBJS="$LIBOBJS lstat.$ac_objext"
  12767. ;;
  12768. esac
  12769. fi
  12770. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat accepts an empty string" >&5
  12771. $as_echo_n "checking whether stat accepts an empty string... " >&6; }
  12772. if ${ac_cv_func_stat_empty_string_bug+:} false; then :
  12773. $as_echo_n "(cached) " >&6
  12774. else
  12775. if test "$cross_compiling" = yes; then :
  12776. ac_cv_func_stat_empty_string_bug=yes
  12777. else
  12778. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12779. /* end confdefs.h. */
  12780. $ac_includes_default
  12781. int
  12782. main ()
  12783. {
  12784. struct stat sbuf;
  12785. return stat ("", &sbuf) == 0;
  12786. ;
  12787. return 0;
  12788. }
  12789. _ACEOF
  12790. if ac_fn_c_try_run "$LINENO"; then :
  12791. ac_cv_func_stat_empty_string_bug=no
  12792. else
  12793. ac_cv_func_stat_empty_string_bug=yes
  12794. fi
  12795. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12796. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12797. fi
  12798. fi
  12799. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_stat_empty_string_bug" >&5
  12800. $as_echo "$ac_cv_func_stat_empty_string_bug" >&6; }
  12801. if test $ac_cv_func_stat_empty_string_bug = yes; then
  12802. case " $LIBOBJS " in
  12803. *" stat.$ac_objext "* ) ;;
  12804. *) LIBOBJS="$LIBOBJS stat.$ac_objext"
  12805. ;;
  12806. esac
  12807. cat >>confdefs.h <<_ACEOF
  12808. #define HAVE_STAT_EMPTY_STRING_BUG 1
  12809. _ACEOF
  12810. fi
  12811. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strcoll" >&5
  12812. $as_echo_n "checking for working strcoll... " >&6; }
  12813. if ${ac_cv_func_strcoll_works+:} false; then :
  12814. $as_echo_n "(cached) " >&6
  12815. else
  12816. if test "$cross_compiling" = yes; then :
  12817. ac_cv_func_strcoll_works=no
  12818. else
  12819. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12820. /* end confdefs.h. */
  12821. $ac_includes_default
  12822. int
  12823. main ()
  12824. {
  12825. return (strcoll ("abc", "def") >= 0 ||
  12826. strcoll ("ABC", "DEF") >= 0 ||
  12827. strcoll ("123", "456") >= 0)
  12828. ;
  12829. return 0;
  12830. }
  12831. _ACEOF
  12832. if ac_fn_c_try_run "$LINENO"; then :
  12833. ac_cv_func_strcoll_works=yes
  12834. else
  12835. ac_cv_func_strcoll_works=no
  12836. fi
  12837. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12838. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12839. fi
  12840. fi
  12841. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strcoll_works" >&5
  12842. $as_echo "$ac_cv_func_strcoll_works" >&6; }
  12843. if test $ac_cv_func_strcoll_works = yes; then
  12844. $as_echo "#define HAVE_STRCOLL 1" >>confdefs.h
  12845. fi
  12846. for ac_func in strftime
  12847. do :
  12848. ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
  12849. if test "x$ac_cv_func_strftime" = xyes; then :
  12850. cat >>confdefs.h <<_ACEOF
  12851. #define HAVE_STRFTIME 1
  12852. _ACEOF
  12853. else
  12854. # strftime is in -lintl on SCO UNIX.
  12855. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5
  12856. $as_echo_n "checking for strftime in -lintl... " >&6; }
  12857. if ${ac_cv_lib_intl_strftime+:} false; then :
  12858. $as_echo_n "(cached) " >&6
  12859. else
  12860. ac_check_lib_save_LIBS=$LIBS
  12861. LIBS="-lintl $LIBS"
  12862. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12863. /* end confdefs.h. */
  12864. /* Override any GCC internal prototype to avoid an error.
  12865. Use char because int might match the return type of a GCC
  12866. builtin and then its argument prototype would still apply. */
  12867. #ifdef __cplusplus
  12868. extern "C"
  12869. #endif
  12870. char strftime ();
  12871. int
  12872. main ()
  12873. {
  12874. return strftime ();
  12875. ;
  12876. return 0;
  12877. }
  12878. _ACEOF
  12879. if ac_fn_c_try_link "$LINENO"; then :
  12880. ac_cv_lib_intl_strftime=yes
  12881. else
  12882. ac_cv_lib_intl_strftime=no
  12883. fi
  12884. rm -f core conftest.err conftest.$ac_objext \
  12885. conftest$ac_exeext conftest.$ac_ext
  12886. LIBS=$ac_check_lib_save_LIBS
  12887. fi
  12888. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5
  12889. $as_echo "$ac_cv_lib_intl_strftime" >&6; }
  12890. if test "x$ac_cv_lib_intl_strftime" = xyes; then :
  12891. $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
  12892. LIBS="-lintl $LIBS"
  12893. fi
  12894. fi
  12895. done
  12896. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
  12897. $as_echo_n "checking for working strnlen... " >&6; }
  12898. if ${ac_cv_func_strnlen_working+:} false; then :
  12899. $as_echo_n "(cached) " >&6
  12900. else
  12901. if test "$cross_compiling" = yes; then :
  12902. # Guess no on AIX systems, yes otherwise.
  12903. case "$host_os" in
  12904. aix*) ac_cv_func_strnlen_working=no;;
  12905. *) ac_cv_func_strnlen_working=yes;;
  12906. esac
  12907. else
  12908. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12909. /* end confdefs.h. */
  12910. $ac_includes_default
  12911. int
  12912. main ()
  12913. {
  12914. #define S "foobar"
  12915. #define S_LEN (sizeof S - 1)
  12916. /* At least one implementation is buggy: that of AIX 4.3 would
  12917. give strnlen (S, 1) == 3. */
  12918. int i;
  12919. for (i = 0; i < S_LEN + 1; ++i)
  12920. {
  12921. int expected = i <= S_LEN ? i : S_LEN;
  12922. if (strnlen (S, i) != expected)
  12923. return 1;
  12924. }
  12925. return 0;
  12926. ;
  12927. return 0;
  12928. }
  12929. _ACEOF
  12930. if ac_fn_c_try_run "$LINENO"; then :
  12931. ac_cv_func_strnlen_working=yes
  12932. else
  12933. ac_cv_func_strnlen_working=no
  12934. fi
  12935. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12936. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12937. fi
  12938. fi
  12939. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
  12940. $as_echo "$ac_cv_func_strnlen_working" >&6; }
  12941. test $ac_cv_func_strnlen_working = no && case " $LIBOBJS " in
  12942. *" strnlen.$ac_objext "* ) ;;
  12943. *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
  12944. ;;
  12945. esac
  12946. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strtod" >&5
  12947. $as_echo_n "checking for working strtod... " >&6; }
  12948. if ${ac_cv_func_strtod+:} false; then :
  12949. $as_echo_n "(cached) " >&6
  12950. else
  12951. if test "$cross_compiling" = yes; then :
  12952. ac_cv_func_strtod=no
  12953. else
  12954. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  12955. /* end confdefs.h. */
  12956. $ac_includes_default
  12957. #ifndef strtod
  12958. double strtod ();
  12959. #endif
  12960. int
  12961. main()
  12962. {
  12963. {
  12964. /* Some versions of Linux strtod mis-parse strings with leading '+'. */
  12965. char *string = " +69";
  12966. char *term;
  12967. double value;
  12968. value = strtod (string, &term);
  12969. if (value != 69 || term != (string + 4))
  12970. return 1;
  12971. }
  12972. {
  12973. /* Under Solaris 2.4, strtod returns the wrong value for the
  12974. terminating character under some conditions. */
  12975. char *string = "NaN";
  12976. char *term;
  12977. strtod (string, &term);
  12978. if (term != string && *(term - 1) == 0)
  12979. return 1;
  12980. }
  12981. return 0;
  12982. }
  12983. _ACEOF
  12984. if ac_fn_c_try_run "$LINENO"; then :
  12985. ac_cv_func_strtod=yes
  12986. else
  12987. ac_cv_func_strtod=no
  12988. fi
  12989. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  12990. conftest.$ac_objext conftest.beam conftest.$ac_ext
  12991. fi
  12992. fi
  12993. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strtod" >&5
  12994. $as_echo "$ac_cv_func_strtod" >&6; }
  12995. if test $ac_cv_func_strtod = no; then
  12996. case " $LIBOBJS " in
  12997. *" strtod.$ac_objext "* ) ;;
  12998. *) LIBOBJS="$LIBOBJS strtod.$ac_objext"
  12999. ;;
  13000. esac
  13001. ac_fn_c_check_func "$LINENO" "pow" "ac_cv_func_pow"
  13002. if test "x$ac_cv_func_pow" = xyes; then :
  13003. fi
  13004. if test $ac_cv_func_pow = no; then
  13005. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pow in -lm" >&5
  13006. $as_echo_n "checking for pow in -lm... " >&6; }
  13007. if ${ac_cv_lib_m_pow+:} false; then :
  13008. $as_echo_n "(cached) " >&6
  13009. else
  13010. ac_check_lib_save_LIBS=$LIBS
  13011. LIBS="-lm $LIBS"
  13012. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13013. /* end confdefs.h. */
  13014. /* Override any GCC internal prototype to avoid an error.
  13015. Use char because int might match the return type of a GCC
  13016. builtin and then its argument prototype would still apply. */
  13017. #ifdef __cplusplus
  13018. extern "C"
  13019. #endif
  13020. char pow ();
  13021. int
  13022. main ()
  13023. {
  13024. return pow ();
  13025. ;
  13026. return 0;
  13027. }
  13028. _ACEOF
  13029. if ac_fn_c_try_link "$LINENO"; then :
  13030. ac_cv_lib_m_pow=yes
  13031. else
  13032. ac_cv_lib_m_pow=no
  13033. fi
  13034. rm -f core conftest.err conftest.$ac_objext \
  13035. conftest$ac_exeext conftest.$ac_ext
  13036. LIBS=$ac_check_lib_save_LIBS
  13037. fi
  13038. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_pow" >&5
  13039. $as_echo "$ac_cv_lib_m_pow" >&6; }
  13040. if test "x$ac_cv_lib_m_pow" = xyes; then :
  13041. POW_LIB=-lm
  13042. else
  13043. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot find library containing definition of pow" >&5
  13044. $as_echo "$as_me: WARNING: cannot find library containing definition of pow" >&2;}
  13045. fi
  13046. fi
  13047. fi
  13048. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether utime accepts a null argument" >&5
  13049. $as_echo_n "checking whether utime accepts a null argument... " >&6; }
  13050. if ${ac_cv_func_utime_null+:} false; then :
  13051. $as_echo_n "(cached) " >&6
  13052. else
  13053. rm -f conftest.data; >conftest.data
  13054. # Sequent interprets utime(file, 0) to mean use start of epoch. Wrong.
  13055. if test "$cross_compiling" = yes; then :
  13056. ac_cv_func_utime_null='guessing yes'
  13057. else
  13058. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13059. /* end confdefs.h. */
  13060. $ac_includes_default
  13061. #ifdef HAVE_UTIME_H
  13062. # include <utime.h>
  13063. #endif
  13064. int
  13065. main ()
  13066. {
  13067. struct stat s, t;
  13068. return ! (stat ("conftest.data", &s) == 0
  13069. && utime ("conftest.data", 0) == 0
  13070. && stat ("conftest.data", &t) == 0
  13071. && t.st_mtime >= s.st_mtime
  13072. && t.st_mtime - s.st_mtime < 120);
  13073. ;
  13074. return 0;
  13075. }
  13076. _ACEOF
  13077. if ac_fn_c_try_run "$LINENO"; then :
  13078. ac_cv_func_utime_null=yes
  13079. else
  13080. ac_cv_func_utime_null=no
  13081. fi
  13082. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13083. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13084. fi
  13085. fi
  13086. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_utime_null" >&5
  13087. $as_echo "$ac_cv_func_utime_null" >&6; }
  13088. if test "x$ac_cv_func_utime_null" != xno; then
  13089. ac_cv_func_utime_null=yes
  13090. $as_echo "#define HAVE_UTIME_NULL 1" >>confdefs.h
  13091. fi
  13092. rm -f conftest.data
  13093. for ac_func in vprintf
  13094. do :
  13095. ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf"
  13096. if test "x$ac_cv_func_vprintf" = xyes; then :
  13097. cat >>confdefs.h <<_ACEOF
  13098. #define HAVE_VPRINTF 1
  13099. _ACEOF
  13100. ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
  13101. if test "x$ac_cv_func__doprnt" = xyes; then :
  13102. $as_echo "#define HAVE_DOPRNT 1" >>confdefs.h
  13103. fi
  13104. fi
  13105. done
  13106. for ac_func in asprintf atexit closefrom dup2 eaccess endpwent euidaccess ffsll ftruncate getcwd gethostbyname gethostname getloadavg gettimeofday glob ioperm inet_ntoa isascii memchr memmove memset mkdir mkdtemp munmap 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
  13107. do :
  13108. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13109. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13110. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13111. cat >>confdefs.h <<_ACEOF
  13112. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13113. _ACEOF
  13114. fi
  13115. done
  13116. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htonll" >&5
  13117. $as_echo_n "checking for htonll... " >&6; }
  13118. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13119. /* end confdefs.h. */
  13120. #include <arpa/inet.h>
  13121. int
  13122. main ()
  13123. {
  13124. return htonll(0);
  13125. ;
  13126. return 0;
  13127. }
  13128. _ACEOF
  13129. if ac_fn_c_try_link "$LINENO"; then :
  13130. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13131. $as_echo "yes" >&6; }
  13132. $as_echo "#define HAVE_HTONLL 1" >>confdefs.h
  13133. else
  13134. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13135. $as_echo "no" >&6; }
  13136. fi
  13137. rm -f core conftest.err conftest.$ac_objext \
  13138. conftest$ac_exeext conftest.$ac_ext
  13139. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ntohll" >&5
  13140. $as_echo_n "checking for ntohll... " >&6; }
  13141. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13142. /* end confdefs.h. */
  13143. #include <arpa/inet.h>
  13144. int
  13145. main ()
  13146. {
  13147. return ntohll(0);
  13148. ;
  13149. return 0;
  13150. }
  13151. _ACEOF
  13152. if ac_fn_c_try_link "$LINENO"; then :
  13153. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13154. $as_echo "yes" >&6; }
  13155. $as_echo "#define HAVE_NTOHLL 1" >>confdefs.h
  13156. else
  13157. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13158. $as_echo "no" >&6; }
  13159. fi
  13160. rm -f core conftest.err conftest.$ac_objext \
  13161. conftest$ac_exeext conftest.$ac_ext
  13162. # NOTE: we use AC_CHECK_LIB to get -lm into the arguments for later checks,
  13163. # so that AC_CHECK_FUNCS can detect functions in that library.
  13164. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
  13165. $as_echo_n "checking for sqrt in -lm... " >&6; }
  13166. if ${ac_cv_lib_m_sqrt+:} false; then :
  13167. $as_echo_n "(cached) " >&6
  13168. else
  13169. ac_check_lib_save_LIBS=$LIBS
  13170. LIBS="-lm $LIBS"
  13171. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13172. /* end confdefs.h. */
  13173. /* Override any GCC internal prototype to avoid an error.
  13174. Use char because int might match the return type of a GCC
  13175. builtin and then its argument prototype would still apply. */
  13176. #ifdef __cplusplus
  13177. extern "C"
  13178. #endif
  13179. char sqrt ();
  13180. int
  13181. main ()
  13182. {
  13183. return sqrt ();
  13184. ;
  13185. return 0;
  13186. }
  13187. _ACEOF
  13188. if ac_fn_c_try_link "$LINENO"; then :
  13189. ac_cv_lib_m_sqrt=yes
  13190. else
  13191. ac_cv_lib_m_sqrt=no
  13192. fi
  13193. rm -f core conftest.err conftest.$ac_objext \
  13194. conftest$ac_exeext conftest.$ac_ext
  13195. LIBS=$ac_check_lib_save_LIBS
  13196. fi
  13197. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
  13198. $as_echo "$ac_cv_lib_m_sqrt" >&6; }
  13199. if test "x$ac_cv_lib_m_sqrt" = xyes; then :
  13200. cat >>confdefs.h <<_ACEOF
  13201. #define HAVE_LIBM 1
  13202. _ACEOF
  13203. LIBS="-lm $LIBS"
  13204. fi
  13205. # BSD might not have exp2, and/or log2
  13206. 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
  13207. do :
  13208. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13209. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13210. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13211. cat >>confdefs.h <<_ACEOF
  13212. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13213. _ACEOF
  13214. fi
  13215. done
  13216. # Certain architectures don't really have long double, even though
  13217. # AC_CHECK_FUNCS would otherwise find the following functions.
  13218. if test "x${ac_cv_type_long_double_wider}" = "xyes" ; then
  13219. 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
  13220. do :
  13221. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13222. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13223. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13224. cat >>confdefs.h <<_ACEOF
  13225. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13226. _ACEOF
  13227. fi
  13228. done
  13229. fi
  13230. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LLONG_MAX in limits.h" >&5
  13231. $as_echo_n "checking for LLONG_MAX in limits.h... " >&6; }
  13232. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13233. /* end confdefs.h. */
  13234. #include <limits.h>
  13235. int
  13236. main ()
  13237. {
  13238. long long foo = LLONG_MAX
  13239. ;
  13240. return 0;
  13241. }
  13242. _ACEOF
  13243. if ac_fn_c_try_link "$LINENO"; then :
  13244. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13245. $as_echo "yes" >&6; }
  13246. $as_echo "#define HAVE_LLONG_MAX 1" >>confdefs.h
  13247. else
  13248. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13249. $as_echo "no" >&6; }
  13250. fi
  13251. rm -f core conftest.err conftest.$ac_objext \
  13252. conftest$ac_exeext conftest.$ac_ext
  13253. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timersub in time.h" >&5
  13254. $as_echo_n "checking for timersub in time.h... " >&6; }
  13255. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13256. /* end confdefs.h. */
  13257. #include <sys/time.h>
  13258. int
  13259. main ()
  13260. {
  13261. struct timeval *a; timersub(a, a, a);
  13262. ;
  13263. return 0;
  13264. }
  13265. _ACEOF
  13266. if ac_fn_c_try_link "$LINENO"; then :
  13267. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13268. $as_echo "yes" >&6; }
  13269. $as_echo "#define HAVE_TIMERSUB 1" >>confdefs.h
  13270. else
  13271. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13272. $as_echo "no" >&6; }
  13273. fi
  13274. rm -f core conftest.err conftest.$ac_objext \
  13275. conftest$ac_exeext conftest.$ac_ext
  13276. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a version of GNU ld that supports the --dynamic-list flag" >&5
  13277. $as_echo_n "checking for a version of GNU ld that supports the --dynamic-list flag... " >&6; }
  13278. old_LDFLAGS=${LDFLAGS}
  13279. cat >conftest.dynamics <<_ACEOF
  13280. {
  13281. *ast_*;
  13282. };
  13283. _ACEOF
  13284. LDFLAGS="${LDFLAGS} -Wl,--dynamic-list,conftest.dynamics"
  13285. PBX_DYNAMIC_LIST=0
  13286. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13287. /* end confdefs.h. */
  13288. int
  13289. main ()
  13290. {
  13291. ;
  13292. return 0;
  13293. }
  13294. _ACEOF
  13295. if ac_fn_c_try_link "$LINENO"; then :
  13296. PBX_DYNAMIC_LIST=1
  13297. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13298. $as_echo "yes" >&6; }
  13299. else
  13300. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13301. $as_echo "no" >&6; }
  13302. fi
  13303. rm -f core conftest.err conftest.$ac_objext \
  13304. conftest$ac_exeext conftest.$ac_ext
  13305. LDFLAGS=${old_LDFLAGS}
  13306. rm -f conftest.dynamics
  13307. ac_fn_c_check_header_mongrel "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default"
  13308. if test "x$ac_cv_header_sys_poll_h" = xyes; then :
  13309. HAS_POLL=1
  13310. $as_echo "#define HAVE_SYS_POLL_H 1" >>confdefs.h
  13311. fi
  13312. # Check whether --enable-internal-poll was given.
  13313. if test "${enable_internal_poll+set}" = set; then :
  13314. enableval=$enable_internal_poll; case "${enableval}" in
  13315. y|ye|yes) HAS_POLL="";;
  13316. n|no) HAS_POLL="${HAS_POLL}" ;;
  13317. *) as_fn_error $? "bad value ${enableval} for --enable-internal-poll" "$LINENO" 5 ;;
  13318. esac
  13319. fi
  13320. # Check whether --enable-asteriskssl was given.
  13321. if test "${enable_asteriskssl+set}" = set; then :
  13322. enableval=$enable_asteriskssl; case "${enableval}" in
  13323. y|ye|yes) AST_ASTERISKSSL=yes ;;
  13324. n|no) AST_ASTERISKSSL=no ;;
  13325. *) as_fn_error $? "bad value ${enableval} for --disable-asteriskssl" "$LINENO" 5 ;;
  13326. esac
  13327. else
  13328. AST_ASTERISKSSL=yes
  13329. fi
  13330. # https support (in main/http.c) uses funopen on BSD systems,
  13331. # fopencookie on linux
  13332. for ac_func in funopen fopencookie
  13333. do :
  13334. as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
  13335. ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
  13336. if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
  13337. cat >>confdefs.h <<_ACEOF
  13338. #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
  13339. _ACEOF
  13340. fi
  13341. done
  13342. for ac_func in inet_aton
  13343. do :
  13344. ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
  13345. if test "x$ac_cv_func_inet_aton" = xyes; then :
  13346. cat >>confdefs.h <<_ACEOF
  13347. #define HAVE_INET_ATON 1
  13348. _ACEOF
  13349. fi
  13350. done
  13351. # check if we have IP_PKTINFO constant defined
  13352. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IP_PKTINFO" >&5
  13353. $as_echo_n "checking for IP_PKTINFO... " >&6; }
  13354. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13355. /* end confdefs.h. */
  13356. #include <netinet/in.h>
  13357. int
  13358. main ()
  13359. {
  13360. int pi = IP_PKTINFO;
  13361. ;
  13362. return 0;
  13363. }
  13364. _ACEOF
  13365. if ac_fn_c_try_link "$LINENO"; then :
  13366. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13367. $as_echo "yes" >&6; }
  13368. $as_echo "#define HAVE_PKTINFO 1" >>confdefs.h
  13369. else
  13370. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13371. $as_echo "no" >&6; }
  13372. fi
  13373. rm -f core conftest.err conftest.$ac_objext \
  13374. conftest$ac_exeext conftest.$ac_ext
  13375. # some systems already have gethostbyname_r so we don't need to build ours in main/utils.c
  13376. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname_r" >&5
  13377. $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
  13378. if ${ac_cv_search_gethostbyname_r+:} false; then :
  13379. $as_echo_n "(cached) " >&6
  13380. else
  13381. ac_func_search_save_LIBS=$LIBS
  13382. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13383. /* end confdefs.h. */
  13384. /* Override any GCC internal prototype to avoid an error.
  13385. Use char because int might match the return type of a GCC
  13386. builtin and then its argument prototype would still apply. */
  13387. #ifdef __cplusplus
  13388. extern "C"
  13389. #endif
  13390. char gethostbyname_r ();
  13391. int
  13392. main ()
  13393. {
  13394. return gethostbyname_r ();
  13395. ;
  13396. return 0;
  13397. }
  13398. _ACEOF
  13399. for ac_lib in '' socket nsl; do
  13400. if test -z "$ac_lib"; then
  13401. ac_res="none required"
  13402. else
  13403. ac_res=-l$ac_lib
  13404. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  13405. fi
  13406. if ac_fn_c_try_link "$LINENO"; then :
  13407. ac_cv_search_gethostbyname_r=$ac_res
  13408. fi
  13409. rm -f core conftest.err conftest.$ac_objext \
  13410. conftest$ac_exeext
  13411. if ${ac_cv_search_gethostbyname_r+:} false; then :
  13412. break
  13413. fi
  13414. done
  13415. if ${ac_cv_search_gethostbyname_r+:} false; then :
  13416. else
  13417. ac_cv_search_gethostbyname_r=no
  13418. fi
  13419. rm conftest.$ac_ext
  13420. LIBS=$ac_func_search_save_LIBS
  13421. fi
  13422. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname_r" >&5
  13423. $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
  13424. ac_res=$ac_cv_search_gethostbyname_r
  13425. if test "$ac_res" != no; then :
  13426. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  13427. fi
  13428. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname_r with 6 arguments" >&5
  13429. $as_echo_n "checking for gethostbyname_r with 6 arguments... " >&6; }
  13430. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13431. /* end confdefs.h. */
  13432. #include <stdlib.h>
  13433. #include <netdb.h>
  13434. int
  13435. main ()
  13436. {
  13437. struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (struct hostent **)NULL, (int *)NULL);
  13438. ;
  13439. return 0;
  13440. }
  13441. _ACEOF
  13442. if ac_fn_c_try_link "$LINENO"; then :
  13443. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13444. $as_echo "yes" >&6; }
  13445. $as_echo "#define HAVE_GETHOSTBYNAME_R_6 1" >>confdefs.h
  13446. else
  13447. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13448. $as_echo "no" >&6; }
  13449. fi
  13450. rm -f core conftest.err conftest.$ac_objext \
  13451. conftest$ac_exeext conftest.$ac_ext
  13452. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname_r with 5 arguments" >&5
  13453. $as_echo_n "checking for gethostbyname_r with 5 arguments... " >&6; }
  13454. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13455. /* end confdefs.h. */
  13456. #include <stdlib.h>
  13457. #include <netdb.h>
  13458. int
  13459. main ()
  13460. {
  13461. struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (int *)NULL);
  13462. ;
  13463. return 0;
  13464. }
  13465. _ACEOF
  13466. if ac_fn_c_try_link "$LINENO"; then :
  13467. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13468. $as_echo "yes" >&6; }
  13469. $as_echo "#define HAVE_GETHOSTBYNAME_R_5 1" >>confdefs.h
  13470. else
  13471. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13472. $as_echo "no" >&6; }
  13473. fi
  13474. rm -f core conftest.err conftest.$ac_objext \
  13475. conftest$ac_exeext conftest.$ac_ext
  13476. ac_fn_c_check_header_mongrel "$LINENO" "byteswap.h" "ac_cv_header_byteswap_h" "$ac_includes_default"
  13477. if test "x$ac_cv_header_byteswap_h" = xyes; then :
  13478. cat >>confdefs.h <<_ACEOF
  13479. #define HAVE_BYTESWAP_H 1
  13480. _ACEOF
  13481. fi
  13482. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __swap16 variant of <sys/endian.h> byteswapping macros" >&5
  13483. $as_echo_n "checking for __swap16 variant of <sys/endian.h> byteswapping macros... " >&6; }
  13484. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13485. /* end confdefs.h. */
  13486. #include <sys/endian.h>
  13487. int
  13488. main ()
  13489. {
  13490. int a = 1; int b = __swap16(a);
  13491. ;
  13492. return 0;
  13493. }
  13494. _ACEOF
  13495. if ac_fn_c_try_link "$LINENO"; then :
  13496. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13497. $as_echo "yes" >&6; }
  13498. $as_echo "#define HAVE_SYS_ENDIAN_SWAP16 1" >>confdefs.h
  13499. else
  13500. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13501. $as_echo "no" >&6; }
  13502. fi
  13503. rm -f core conftest.err conftest.$ac_objext \
  13504. conftest$ac_exeext conftest.$ac_ext
  13505. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bswap16 variant of <sys/endian.h> byteswapping macros" >&5
  13506. $as_echo_n "checking for bswap16 variant of <sys/endian.h> byteswapping macros... " >&6; }
  13507. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13508. /* end confdefs.h. */
  13509. #include <sys/endian.h>
  13510. int
  13511. main ()
  13512. {
  13513. int a = 1; int b = bswap16(a);
  13514. ;
  13515. return 0;
  13516. }
  13517. _ACEOF
  13518. if ac_fn_c_try_link "$LINENO"; then :
  13519. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13520. $as_echo "yes" >&6; }
  13521. $as_echo "#define HAVE_SYS_ENDIAN_BSWAP16 1" >>confdefs.h
  13522. else
  13523. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13524. $as_echo "no" >&6; }
  13525. fi
  13526. rm -f core conftest.err conftest.$ac_objext \
  13527. conftest$ac_exeext conftest.$ac_ext
  13528. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t in locale.h" >&5
  13529. $as_echo_n "checking for locale_t in locale.h... " >&6; }
  13530. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13531. /* end confdefs.h. */
  13532. #include <locale.h>
  13533. int
  13534. main ()
  13535. {
  13536. locale_t lt = NULL
  13537. ;
  13538. return 0;
  13539. }
  13540. _ACEOF
  13541. if ac_fn_c_try_link "$LINENO"; then :
  13542. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13543. $as_echo "yes" >&6; }
  13544. $as_echo "#define HAVE_LOCALE_T_IN_LOCALE_H 1" >>confdefs.h
  13545. else
  13546. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13547. $as_echo "no" >&6; }
  13548. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for locale_t in xlocale.h" >&5
  13549. $as_echo_n "checking for locale_t in xlocale.h... " >&6; }
  13550. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13551. /* end confdefs.h. */
  13552. #include <xlocale.h>
  13553. int
  13554. main ()
  13555. {
  13556. locale_t lt = NULL
  13557. ;
  13558. return 0;
  13559. }
  13560. _ACEOF
  13561. if ac_fn_c_try_link "$LINENO"; then :
  13562. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13563. $as_echo "yes" >&6; }
  13564. $as_echo "#define HAVE_LOCALE_T_IN_XLOCALE_H 1" >>confdefs.h
  13565. else
  13566. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13567. $as_echo "no" >&6; }
  13568. fi
  13569. rm -f core conftest.err conftest.$ac_objext \
  13570. conftest$ac_exeext conftest.$ac_ext
  13571. fi
  13572. rm -f core conftest.err conftest.$ac_objext \
  13573. conftest$ac_exeext conftest.$ac_ext
  13574. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for O_EVTONLY in fcntl.h" >&5
  13575. $as_echo_n "checking for O_EVTONLY in fcntl.h... " >&6; }
  13576. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13577. /* end confdefs.h. */
  13578. #include <fcntl.h>
  13579. int
  13580. main ()
  13581. {
  13582. int a = O_EVTONLY;
  13583. ;
  13584. return 0;
  13585. }
  13586. _ACEOF
  13587. if ac_fn_c_try_link "$LINENO"; then :
  13588. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13589. $as_echo "yes" >&6; }
  13590. $as_echo "#define HAVE_O_EVTONLY 1" >>confdefs.h
  13591. else
  13592. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13593. $as_echo "no" >&6; }
  13594. fi
  13595. rm -f core conftest.err conftest.$ac_objext \
  13596. conftest$ac_exeext conftest.$ac_ext
  13597. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for O_SYMLINK in fcntl.h" >&5
  13598. $as_echo_n "checking for O_SYMLINK in fcntl.h... " >&6; }
  13599. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13600. /* end confdefs.h. */
  13601. #include <fcntl.h>
  13602. int
  13603. main ()
  13604. {
  13605. int a = O_SYMLINK;
  13606. ;
  13607. return 0;
  13608. }
  13609. _ACEOF
  13610. if ac_fn_c_try_link "$LINENO"; then :
  13611. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13612. $as_echo "yes" >&6; }
  13613. $as_echo "#define HAVE_O_SYMLINK 1" >>confdefs.h
  13614. else
  13615. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13616. $as_echo "no" >&6; }
  13617. fi
  13618. rm -f core conftest.err conftest.$ac_objext \
  13619. conftest$ac_exeext conftest.$ac_ext
  13620. if test "x${PBX_PTHREAD_RWLOCK_INITIALIZER}" != "x1"; then
  13621. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_RWLOCK_INITIALIZER in pthread.h" >&5
  13622. $as_echo_n "checking for PTHREAD_RWLOCK_INITIALIZER in pthread.h... " >&6; }
  13623. saved_cppflags="${CPPFLAGS}"
  13624. if test "x${PTHREAD_RWLOCK_INITIALIZER_DIR}" != "x"; then
  13625. PTHREAD_RWLOCK_INITIALIZER_INCLUDE="-I${PTHREAD_RWLOCK_INITIALIZER_DIR}/include"
  13626. fi
  13627. CPPFLAGS="${CPPFLAGS} ${PTHREAD_RWLOCK_INITIALIZER_INCLUDE}"
  13628. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13629. /* end confdefs.h. */
  13630. #include <pthread.h>
  13631. int
  13632. main ()
  13633. {
  13634. #if defined(PTHREAD_RWLOCK_INITIALIZER)
  13635. int foo = 0;
  13636. #else
  13637. int foo = bar;
  13638. #endif
  13639. 0
  13640. ;
  13641. return 0;
  13642. }
  13643. _ACEOF
  13644. if ac_fn_c_try_compile "$LINENO"; then :
  13645. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13646. $as_echo "yes" >&6; }
  13647. PBX_PTHREAD_RWLOCK_INITIALIZER=1
  13648. $as_echo "#define HAVE_PTHREAD_RWLOCK_INITIALIZER 1" >>confdefs.h
  13649. else
  13650. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13651. $as_echo "no" >&6; }
  13652. fi
  13653. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13654. CPPFLAGS="${saved_cppflags}"
  13655. fi
  13656. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_RWLOCK_PREFER_WRITER_NP in pthread.h" >&5
  13657. $as_echo_n "checking for PTHREAD_RWLOCK_PREFER_WRITER_NP in pthread.h... " >&6; }
  13658. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13659. /* end confdefs.h. */
  13660. #include <pthread.h>
  13661. int
  13662. main ()
  13663. {
  13664. int a = PTHREAD_RWLOCK_PREFER_WRITER_NP;
  13665. ;
  13666. return 0;
  13667. }
  13668. _ACEOF
  13669. if ac_fn_c_try_link "$LINENO"; then :
  13670. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13671. $as_echo "yes" >&6; }
  13672. $as_echo "#define HAVE_PTHREAD_RWLOCK_PREFER_WRITER_NP 1" >>confdefs.h
  13673. else
  13674. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13675. $as_echo "no" >&6; }
  13676. fi
  13677. rm -f core conftest.err conftest.$ac_objext \
  13678. conftest$ac_exeext conftest.$ac_ext
  13679. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_MUTEX_RECURSIVE_NP in pthread.h" >&5
  13680. $as_echo_n "checking for PTHREAD_MUTEX_RECURSIVE_NP in pthread.h... " >&6; }
  13681. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13682. /* end confdefs.h. */
  13683. #include <pthread.h>
  13684. int
  13685. main ()
  13686. {
  13687. int a = PTHREAD_MUTEX_RECURSIVE_NP;
  13688. ;
  13689. return 0;
  13690. }
  13691. _ACEOF
  13692. if ac_fn_c_try_link "$LINENO"; then :
  13693. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13694. $as_echo "yes" >&6; }
  13695. $as_echo "#define HAVE_PTHREAD_MUTEX_RECURSIVE_NP 1" >>confdefs.h
  13696. else
  13697. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13698. $as_echo "no" >&6; }
  13699. fi
  13700. rm -f core conftest.err conftest.$ac_objext \
  13701. conftest$ac_exeext conftest.$ac_ext
  13702. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_MUTEX_ADAPTIVE_NP in pthread.h" >&5
  13703. $as_echo_n "checking for PTHREAD_MUTEX_ADAPTIVE_NP in pthread.h... " >&6; }
  13704. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13705. /* end confdefs.h. */
  13706. #include <pthread.h>
  13707. int
  13708. main ()
  13709. {
  13710. int a = PTHREAD_MUTEX_ADAPTIVE_NP;
  13711. ;
  13712. return 0;
  13713. }
  13714. _ACEOF
  13715. if ac_fn_c_try_link "$LINENO"; then :
  13716. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13717. $as_echo "yes" >&6; }
  13718. $as_echo "#define HAVE_PTHREAD_MUTEX_ADAPTIVE_NP 1" >>confdefs.h
  13719. else
  13720. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13721. $as_echo "no" >&6; }
  13722. fi
  13723. rm -f core conftest.err conftest.$ac_objext \
  13724. conftest$ac_exeext conftest.$ac_ext
  13725. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_spinlock_t in pthread.h" >&5
  13726. $as_echo_n "checking for pthread_spinlock_t in pthread.h... " >&6; }
  13727. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13728. /* end confdefs.h. */
  13729. #include <pthread.h>
  13730. int
  13731. main ()
  13732. {
  13733. pthread_spinlock_t spin;
  13734. ;
  13735. return 0;
  13736. }
  13737. _ACEOF
  13738. if ac_fn_c_try_link "$LINENO"; then :
  13739. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13740. $as_echo "yes" >&6; }
  13741. $as_echo "#define HAVE_PTHREAD_SPINLOCK 1" >>confdefs.h
  13742. else
  13743. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13744. $as_echo "no" >&6; }
  13745. fi
  13746. rm -f core conftest.err conftest.$ac_objext \
  13747. conftest$ac_exeext conftest.$ac_ext
  13748. save_LIBS="$LIBS"
  13749. save_CFLAGS="$CFLAGS"
  13750. LIBS="$PTHREAD_LIBS $LIBS"
  13751. CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
  13752. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_timedwrlock() in pthread.h" >&5
  13753. $as_echo_n "checking for pthread_rwlock_timedwrlock() in pthread.h... " >&6; }
  13754. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13755. /* end confdefs.h. */
  13756. #include <pthread.h>
  13757. #include <time.h>
  13758. int
  13759. main ()
  13760. {
  13761. pthread_rwlock_t foo; struct timespec bar; pthread_rwlock_timedwrlock(&foo, &bar)
  13762. ;
  13763. return 0;
  13764. }
  13765. _ACEOF
  13766. if ac_fn_c_try_link "$LINENO"; then :
  13767. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13768. $as_echo "yes" >&6; }
  13769. ac_cv_pthread_rwlock_timedwrlock="yes"
  13770. else
  13771. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13772. $as_echo "no" >&6; }
  13773. ac_cv_pthread_rwlock_timedwrlock="no"
  13774. fi
  13775. rm -f core conftest.err conftest.$ac_objext \
  13776. conftest$ac_exeext conftest.$ac_ext
  13777. # Some platforms define sem_init(), but only support sem_open(). joyous.
  13778. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working unnamed semaphores" >&5
  13779. $as_echo_n "checking for working unnamed semaphores... " >&6; }
  13780. if test "$cross_compiling" = yes; then :
  13781. { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile" >&5
  13782. $as_echo "cross-compile" >&6; }
  13783. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result yes guessed because of cross compilation" >&5
  13784. $as_echo "$as_me: WARNING: result yes guessed because of cross compilation" >&6;}
  13785. $as_echo "#define HAS_WORKING_SEMAPHORE 1" >>confdefs.h
  13786. else
  13787. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13788. /* end confdefs.h. */
  13789. #include <semaphore.h>
  13790. int
  13791. main ()
  13792. {
  13793. sem_t sem; return sem_init(&sem, 0, 0);
  13794. ;
  13795. return 0;
  13796. }
  13797. _ACEOF
  13798. if ac_fn_c_try_run "$LINENO"; then :
  13799. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13800. $as_echo "yes" >&6; }
  13801. $as_echo "#define HAS_WORKING_SEMAPHORE 1" >>confdefs.h
  13802. else
  13803. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13804. $as_echo "no" >&6; }
  13805. fi
  13806. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13807. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13808. fi
  13809. LIBS="$save_LIBS"
  13810. CFLAGS="$save_CFLAGS"
  13811. if test "${ac_cv_pthread_rwlock_timedwrlock}" = "yes"; then
  13812. $as_echo "#define HAVE_PTHREAD_RWLOCK_TIMEDWRLOCK 1" >>confdefs.h
  13813. fi
  13814. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PTHREAD_ONCE_INIT needs braces" >&5
  13815. $as_echo_n "checking if PTHREAD_ONCE_INIT needs braces... " >&6; }
  13816. saved_CFLAGS="${CFLAGS}"
  13817. CFLAGS="${CFLAGS} -Werror -Wmissing-braces"
  13818. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13819. /* end confdefs.h. */
  13820. #include <pthread.h>
  13821. void empty(){}
  13822. int
  13823. main ()
  13824. {
  13825. pthread_once_t once = PTHREAD_ONCE_INIT; pthread_once(&once, empty);
  13826. ;
  13827. return 0;
  13828. }
  13829. _ACEOF
  13830. if ac_fn_c_try_compile "$LINENO"; then :
  13831. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13832. $as_echo "no" >&6; }
  13833. ac_cv_pthread_once_needsbraces="no"
  13834. else
  13835. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13836. $as_echo "yes" >&6; }
  13837. ac_cv_pthread_once_needsbraces="yes"
  13838. fi
  13839. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13840. CFLAGS="${saved_CFLAGS}"
  13841. if test "${ac_cv_pthread_once_needsbraces}" = "yes"; then
  13842. $as_echo "#define PTHREAD_ONCE_INIT_NEEDS_BRACES 1" >>confdefs.h
  13843. fi
  13844. if test "x${PBX_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP}" != "x1"; then
  13845. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP in pthread.h" >&5
  13846. $as_echo_n "checking for PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP in pthread.h... " >&6; }
  13847. saved_cppflags="${CPPFLAGS}"
  13848. if test "x${PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_DIR}" != "x"; then
  13849. PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_INCLUDE="-I${PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_DIR}/include"
  13850. fi
  13851. CPPFLAGS="${CPPFLAGS} ${PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP_INCLUDE}"
  13852. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13853. /* end confdefs.h. */
  13854. #include <pthread.h>
  13855. int
  13856. main ()
  13857. {
  13858. #if defined(PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP)
  13859. int foo = 0;
  13860. #else
  13861. int foo = bar;
  13862. #endif
  13863. 0
  13864. ;
  13865. return 0;
  13866. }
  13867. _ACEOF
  13868. if ac_fn_c_try_compile "$LINENO"; then :
  13869. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13870. $as_echo "yes" >&6; }
  13871. PBX_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP=1
  13872. $as_echo "#define HAVE_PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP 1" >>confdefs.h
  13873. else
  13874. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13875. $as_echo "no" >&6; }
  13876. fi
  13877. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  13878. CPPFLAGS="${saved_cppflags}"
  13879. fi
  13880. # Can we compare a mutex to its initial value?
  13881. # Generally yes on OpenBSD/FreeBSD and no on Mac OS X.
  13882. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can compare a mutex to its initial value" >&5
  13883. $as_echo_n "checking whether we can compare a mutex to its initial value... " >&6; }
  13884. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13885. /* end confdefs.h. */
  13886. #include <pthread.h>
  13887. int
  13888. main ()
  13889. {
  13890. pthread_mutex_t lock;
  13891. if ((lock) != ((pthread_mutex_t) PTHREAD_MUTEX_INITIALIZER)) {
  13892. return 0;
  13893. }
  13894. return 0
  13895. ;
  13896. return 0;
  13897. }
  13898. _ACEOF
  13899. if ac_fn_c_try_link "$LINENO"; then :
  13900. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13901. $as_echo "yes" >&6; }
  13902. $as_echo "#define CAN_COMPARE_MUTEX_TO_INIT_VALUE 1" >>confdefs.h
  13903. else
  13904. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13905. $as_echo "no" >&6; }
  13906. fi
  13907. rm -f core conftest.err conftest.$ac_objext \
  13908. conftest$ac_exeext conftest.$ac_ext
  13909. #if test "${cross_compiling}" = "no";
  13910. #then
  13911. #AC_MSG_CHECKING(for working epoll support)
  13912. #AC_LINK_IFELSE(
  13913. #AC_LANG_PROGRAM([#include <sys/epoll.h>], [int res = epoll_create(10);
  13914. # if (res < 0)
  13915. # return 1;
  13916. # close (res);
  13917. # return 0;]),
  13918. #AC_MSG_RESULT(yes)
  13919. #AC_DEFINE([HAVE_EPOLL], 1, [Define to 1 if your system has working epoll support.]),
  13920. #AC_MSG_RESULT(no)
  13921. #)
  13922. #fi
  13923. # for FreeBSD thr_self
  13924. for ac_header in sys/thr.h
  13925. do :
  13926. ac_fn_c_check_header_mongrel "$LINENO" "sys/thr.h" "ac_cv_header_sys_thr_h" "$ac_includes_default"
  13927. if test "x$ac_cv_header_sys_thr_h" = xyes; then :
  13928. cat >>confdefs.h <<_ACEOF
  13929. #define HAVE_SYS_THR_H 1
  13930. _ACEOF
  13931. fi
  13932. done
  13933. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler atomic operations" >&5
  13934. $as_echo_n "checking for compiler atomic operations... " >&6; }
  13935. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13936. /* end confdefs.h. */
  13937. int
  13938. main ()
  13939. {
  13940. int foo1; int foo2 = __sync_fetch_and_add(&foo1, 1);
  13941. ;
  13942. return 0;
  13943. }
  13944. _ACEOF
  13945. if ac_fn_c_try_link "$LINENO"; then :
  13946. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13947. $as_echo "yes" >&6; }
  13948. $as_echo "#define HAVE_GCC_ATOMICS 1" >>confdefs.h
  13949. else
  13950. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13951. $as_echo "no" >&6; }
  13952. fi
  13953. rm -f core conftest.err conftest.$ac_objext \
  13954. conftest$ac_exeext conftest.$ac_ext
  13955. # glibc, AFAIK, is the only C library that makes printing a NULL to a string safe.
  13956. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system printf is NULL-safe." >&5
  13957. $as_echo_n "checking if your system printf is NULL-safe.... " >&6; }
  13958. if test "$cross_compiling" = yes; then :
  13959. # It's unlikely an embedded system will have this.
  13960. { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5
  13961. $as_echo "unknown" >&6; }
  13962. else
  13963. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13964. /* end confdefs.h. */
  13965. #include <stdio.h>
  13966. int
  13967. main ()
  13968. {
  13969. printf("%s", NULL)
  13970. ;
  13971. return 0;
  13972. }
  13973. _ACEOF
  13974. if ac_fn_c_try_run "$LINENO"; then :
  13975. $as_echo "#define HAVE_NULLSAFE_PRINTF 1" >>confdefs.h
  13976. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  13977. $as_echo "yes" >&6; }
  13978. else
  13979. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  13980. $as_echo "no" >&6; }
  13981. fi
  13982. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  13983. conftest.$ac_objext conftest.beam conftest.$ac_ext
  13984. fi
  13985. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can increase the maximum select-able file descriptor" >&5
  13986. $as_echo_n "checking if we can increase the maximum select-able file descriptor... " >&6; }
  13987. if test "$cross_compiling" = yes; then :
  13988. { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compile" >&5
  13989. $as_echo "cross-compile" >&6; }
  13990. else
  13991. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  13992. /* end confdefs.h. */
  13993. #include <stdio.h>
  13994. #include <sys/select.h>
  13995. #include <sys/time.h>
  13996. #include <sys/resource.h>
  13997. #include <string.h>
  13998. #include <errno.h>
  13999. #include <stdlib.h>
  14000. #include <sys/types.h>
  14001. #include <sys/stat.h>
  14002. #include <fcntl.h>
  14003. #include <unistd.h>
  14004. int
  14005. main ()
  14006. {
  14007. struct rlimit rlim = { FD_SETSIZE * 2, FD_SETSIZE * 2 };
  14008. int fd0, fd1;
  14009. struct timeval tv = { 0, };
  14010. struct ast_fdset { long fds_bits[[1024]]; } fds = { { 0, } };
  14011. if (setrlimit(RLIMIT_NOFILE, &rlim)) { exit(1); }
  14012. if ((fd0 = open("/dev/null", O_RDONLY)) < 0) { exit(1); }
  14013. if (dup2(fd0, (fd1 = FD_SETSIZE + 1)) < 0) { exit(1); }
  14014. FD_SET(fd0, (fd_set *) &fds);
  14015. FD_SET(fd1, (fd_set *) &fds);
  14016. if (select(FD_SETSIZE + 2, (fd_set *) &fds, NULL, NULL, &tv) < 0) { exit(1); }
  14017. exit(0)
  14018. ;
  14019. return 0;
  14020. }
  14021. _ACEOF
  14022. if ac_fn_c_try_run "$LINENO"; then :
  14023. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14024. $as_echo "yes" >&6; }
  14025. $as_echo "#define HAVE_VARIABLE_FDSET 1" >>confdefs.h
  14026. else
  14027. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14028. $as_echo "no" >&6; }
  14029. fi
  14030. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  14031. conftest.$ac_objext conftest.beam conftest.$ac_ext
  14032. fi
  14033. if test "${ac_cv_have_variable_fdset}x" = "0x"; then
  14034. if test "$cross_compiling" = yes; then :
  14035. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  14036. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  14037. as_fn_error $? "cannot run test program while cross compiling
  14038. See \`config.log' for more details" "$LINENO" 5; }
  14039. else
  14040. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14041. /* end confdefs.h. */
  14042. #include <unistd.h>
  14043. #include <sys/types.h>
  14044. #include <stdlib.h>
  14045. int
  14046. main ()
  14047. {
  14048. if (getuid() != 0) { exit(1); }
  14049. ;
  14050. return 0;
  14051. }
  14052. _ACEOF
  14053. if ac_fn_c_try_run "$LINENO"; then :
  14054. $as_echo "#define CONFIGURE_RAN_AS_ROOT 1" >>confdefs.h
  14055. fi
  14056. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  14057. conftest.$ac_objext conftest.beam conftest.$ac_ext
  14058. fi
  14059. fi
  14060. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute pure' support" >&5
  14061. $as_echo_n "checking for compiler 'attribute pure' support... " >&6; }
  14062. saved_CFLAGS="$CFLAGS"
  14063. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14064. if test "x" = "x"
  14065. then
  14066. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14067. /* end confdefs.h. */
  14068. void __attribute__((pure)) *test(void *muffin, ...) {return (void *) 0;}
  14069. int
  14070. main ()
  14071. {
  14072. ;
  14073. return 0;
  14074. }
  14075. _ACEOF
  14076. if ac_fn_c_try_compile "$LINENO"; then :
  14077. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14078. $as_echo "yes" >&6; }
  14079. cat >>confdefs.h <<_ACEOF
  14080. #define HAVE_ATTRIBUTE_pure 1
  14081. _ACEOF
  14082. else
  14083. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14084. $as_echo "no" >&6; }
  14085. fi
  14086. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14087. else
  14088. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14089. /* end confdefs.h. */
  14090. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14091. int
  14092. main ()
  14093. {
  14094. ;
  14095. return 0;
  14096. }
  14097. _ACEOF
  14098. if ac_fn_c_try_compile "$LINENO"; then :
  14099. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14100. $as_echo "yes" >&6; }
  14101. cat >>confdefs.h <<_ACEOF
  14102. #define HAVE_ATTRIBUTE_pure 1
  14103. _ACEOF
  14104. else
  14105. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14106. $as_echo "no" >&6; }
  14107. fi
  14108. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14109. fi
  14110. CFLAGS="$saved_CFLAGS"
  14111. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute malloc' support" >&5
  14112. $as_echo_n "checking for compiler 'attribute malloc' support... " >&6; }
  14113. saved_CFLAGS="$CFLAGS"
  14114. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14115. if test "x" = "x"
  14116. then
  14117. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14118. /* end confdefs.h. */
  14119. void __attribute__((malloc)) *test(void *muffin, ...) {return (void *) 0;}
  14120. int
  14121. main ()
  14122. {
  14123. ;
  14124. return 0;
  14125. }
  14126. _ACEOF
  14127. if ac_fn_c_try_compile "$LINENO"; then :
  14128. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14129. $as_echo "yes" >&6; }
  14130. cat >>confdefs.h <<_ACEOF
  14131. #define HAVE_ATTRIBUTE_malloc 1
  14132. _ACEOF
  14133. else
  14134. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14135. $as_echo "no" >&6; }
  14136. fi
  14137. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14138. else
  14139. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14140. /* end confdefs.h. */
  14141. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14142. int
  14143. main ()
  14144. {
  14145. ;
  14146. return 0;
  14147. }
  14148. _ACEOF
  14149. if ac_fn_c_try_compile "$LINENO"; then :
  14150. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14151. $as_echo "yes" >&6; }
  14152. cat >>confdefs.h <<_ACEOF
  14153. #define HAVE_ATTRIBUTE_malloc 1
  14154. _ACEOF
  14155. else
  14156. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14157. $as_echo "no" >&6; }
  14158. fi
  14159. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14160. fi
  14161. CFLAGS="$saved_CFLAGS"
  14162. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute const' support" >&5
  14163. $as_echo_n "checking for compiler 'attribute const' support... " >&6; }
  14164. saved_CFLAGS="$CFLAGS"
  14165. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14166. if test "x" = "x"
  14167. then
  14168. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14169. /* end confdefs.h. */
  14170. void __attribute__((const)) *test(void *muffin, ...) {return (void *) 0;}
  14171. int
  14172. main ()
  14173. {
  14174. ;
  14175. return 0;
  14176. }
  14177. _ACEOF
  14178. if ac_fn_c_try_compile "$LINENO"; then :
  14179. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14180. $as_echo "yes" >&6; }
  14181. cat >>confdefs.h <<_ACEOF
  14182. #define HAVE_ATTRIBUTE_const 1
  14183. _ACEOF
  14184. else
  14185. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14186. $as_echo "no" >&6; }
  14187. fi
  14188. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14189. else
  14190. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14191. /* end confdefs.h. */
  14192. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14193. int
  14194. main ()
  14195. {
  14196. ;
  14197. return 0;
  14198. }
  14199. _ACEOF
  14200. if ac_fn_c_try_compile "$LINENO"; then :
  14201. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14202. $as_echo "yes" >&6; }
  14203. cat >>confdefs.h <<_ACEOF
  14204. #define HAVE_ATTRIBUTE_const 1
  14205. _ACEOF
  14206. else
  14207. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14208. $as_echo "no" >&6; }
  14209. fi
  14210. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14211. fi
  14212. CFLAGS="$saved_CFLAGS"
  14213. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute unused' support" >&5
  14214. $as_echo_n "checking for compiler 'attribute unused' support... " >&6; }
  14215. saved_CFLAGS="$CFLAGS"
  14216. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14217. if test "x" = "x"
  14218. then
  14219. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14220. /* end confdefs.h. */
  14221. void __attribute__((unused)) *test(void *muffin, ...) {return (void *) 0;}
  14222. int
  14223. main ()
  14224. {
  14225. ;
  14226. return 0;
  14227. }
  14228. _ACEOF
  14229. if ac_fn_c_try_compile "$LINENO"; then :
  14230. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14231. $as_echo "yes" >&6; }
  14232. cat >>confdefs.h <<_ACEOF
  14233. #define HAVE_ATTRIBUTE_unused 1
  14234. _ACEOF
  14235. else
  14236. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14237. $as_echo "no" >&6; }
  14238. fi
  14239. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14240. else
  14241. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14242. /* end confdefs.h. */
  14243. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14244. int
  14245. main ()
  14246. {
  14247. ;
  14248. return 0;
  14249. }
  14250. _ACEOF
  14251. if ac_fn_c_try_compile "$LINENO"; then :
  14252. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14253. $as_echo "yes" >&6; }
  14254. cat >>confdefs.h <<_ACEOF
  14255. #define HAVE_ATTRIBUTE_unused 1
  14256. _ACEOF
  14257. else
  14258. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14259. $as_echo "no" >&6; }
  14260. fi
  14261. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14262. fi
  14263. CFLAGS="$saved_CFLAGS"
  14264. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute always_inline' support" >&5
  14265. $as_echo_n "checking for compiler 'attribute always_inline' support... " >&6; }
  14266. saved_CFLAGS="$CFLAGS"
  14267. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14268. if test "x" = "x"
  14269. then
  14270. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14271. /* end confdefs.h. */
  14272. void __attribute__((always_inline)) *test(void *muffin, ...) {return (void *) 0;}
  14273. int
  14274. main ()
  14275. {
  14276. ;
  14277. return 0;
  14278. }
  14279. _ACEOF
  14280. if ac_fn_c_try_compile "$LINENO"; then :
  14281. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14282. $as_echo "yes" >&6; }
  14283. cat >>confdefs.h <<_ACEOF
  14284. #define HAVE_ATTRIBUTE_always_inline 1
  14285. _ACEOF
  14286. else
  14287. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14288. $as_echo "no" >&6; }
  14289. fi
  14290. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14291. else
  14292. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14293. /* end confdefs.h. */
  14294. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14295. int
  14296. main ()
  14297. {
  14298. ;
  14299. return 0;
  14300. }
  14301. _ACEOF
  14302. if ac_fn_c_try_compile "$LINENO"; then :
  14303. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14304. $as_echo "yes" >&6; }
  14305. cat >>confdefs.h <<_ACEOF
  14306. #define HAVE_ATTRIBUTE_always_inline 1
  14307. _ACEOF
  14308. else
  14309. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14310. $as_echo "no" >&6; }
  14311. fi
  14312. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14313. fi
  14314. CFLAGS="$saved_CFLAGS"
  14315. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute deprecated' support" >&5
  14316. $as_echo_n "checking for compiler 'attribute deprecated' support... " >&6; }
  14317. saved_CFLAGS="$CFLAGS"
  14318. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14319. if test "x" = "x"
  14320. then
  14321. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14322. /* end confdefs.h. */
  14323. void __attribute__((deprecated)) *test(void *muffin, ...) {return (void *) 0;}
  14324. int
  14325. main ()
  14326. {
  14327. ;
  14328. return 0;
  14329. }
  14330. _ACEOF
  14331. if ac_fn_c_try_compile "$LINENO"; then :
  14332. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14333. $as_echo "yes" >&6; }
  14334. cat >>confdefs.h <<_ACEOF
  14335. #define HAVE_ATTRIBUTE_deprecated 1
  14336. _ACEOF
  14337. else
  14338. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14339. $as_echo "no" >&6; }
  14340. fi
  14341. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14342. else
  14343. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14344. /* end confdefs.h. */
  14345. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14346. int
  14347. main ()
  14348. {
  14349. ;
  14350. return 0;
  14351. }
  14352. _ACEOF
  14353. if ac_fn_c_try_compile "$LINENO"; then :
  14354. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14355. $as_echo "yes" >&6; }
  14356. cat >>confdefs.h <<_ACEOF
  14357. #define HAVE_ATTRIBUTE_deprecated 1
  14358. _ACEOF
  14359. else
  14360. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14361. $as_echo "no" >&6; }
  14362. fi
  14363. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14364. fi
  14365. CFLAGS="$saved_CFLAGS"
  14366. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute sentinel' support" >&5
  14367. $as_echo_n "checking for compiler 'attribute sentinel' support... " >&6; }
  14368. saved_CFLAGS="$CFLAGS"
  14369. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14370. if test "x" = "x"
  14371. then
  14372. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14373. /* end confdefs.h. */
  14374. void __attribute__((sentinel)) *test(void *muffin, ...) {return (void *) 0;}
  14375. int
  14376. main ()
  14377. {
  14378. ;
  14379. return 0;
  14380. }
  14381. _ACEOF
  14382. if ac_fn_c_try_compile "$LINENO"; then :
  14383. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14384. $as_echo "yes" >&6; }
  14385. cat >>confdefs.h <<_ACEOF
  14386. #define HAVE_ATTRIBUTE_sentinel 1
  14387. _ACEOF
  14388. else
  14389. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14390. $as_echo "no" >&6; }
  14391. fi
  14392. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14393. else
  14394. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14395. /* end confdefs.h. */
  14396. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14397. int
  14398. main ()
  14399. {
  14400. ;
  14401. return 0;
  14402. }
  14403. _ACEOF
  14404. if ac_fn_c_try_compile "$LINENO"; then :
  14405. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14406. $as_echo "yes" >&6; }
  14407. cat >>confdefs.h <<_ACEOF
  14408. #define HAVE_ATTRIBUTE_sentinel 1
  14409. _ACEOF
  14410. else
  14411. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14412. $as_echo "no" >&6; }
  14413. fi
  14414. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14415. fi
  14416. CFLAGS="$saved_CFLAGS"
  14417. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute warn_unused_result' support" >&5
  14418. $as_echo_n "checking for compiler 'attribute warn_unused_result' support... " >&6; }
  14419. saved_CFLAGS="$CFLAGS"
  14420. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14421. if test "x" = "x"
  14422. then
  14423. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14424. /* end confdefs.h. */
  14425. void __attribute__((warn_unused_result)) *test(void *muffin, ...) {return (void *) 0;}
  14426. int
  14427. main ()
  14428. {
  14429. ;
  14430. return 0;
  14431. }
  14432. _ACEOF
  14433. if ac_fn_c_try_compile "$LINENO"; then :
  14434. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14435. $as_echo "yes" >&6; }
  14436. cat >>confdefs.h <<_ACEOF
  14437. #define HAVE_ATTRIBUTE_warn_unused_result 1
  14438. _ACEOF
  14439. else
  14440. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14441. $as_echo "no" >&6; }
  14442. fi
  14443. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14444. else
  14445. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14446. /* end confdefs.h. */
  14447. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14448. int
  14449. main ()
  14450. {
  14451. ;
  14452. return 0;
  14453. }
  14454. _ACEOF
  14455. if ac_fn_c_try_compile "$LINENO"; then :
  14456. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14457. $as_echo "yes" >&6; }
  14458. cat >>confdefs.h <<_ACEOF
  14459. #define HAVE_ATTRIBUTE_warn_unused_result 1
  14460. _ACEOF
  14461. else
  14462. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14463. $as_echo "no" >&6; }
  14464. fi
  14465. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14466. fi
  14467. CFLAGS="$saved_CFLAGS"
  14468. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute may_alias' support" >&5
  14469. $as_echo_n "checking for compiler 'attribute may_alias' support... " >&6; }
  14470. saved_CFLAGS="$CFLAGS"
  14471. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14472. if test "x" = "x"
  14473. then
  14474. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14475. /* end confdefs.h. */
  14476. void __attribute__((may_alias)) *test(void *muffin, ...) {return (void *) 0;}
  14477. int
  14478. main ()
  14479. {
  14480. ;
  14481. return 0;
  14482. }
  14483. _ACEOF
  14484. if ac_fn_c_try_compile "$LINENO"; then :
  14485. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14486. $as_echo "yes" >&6; }
  14487. cat >>confdefs.h <<_ACEOF
  14488. #define HAVE_ATTRIBUTE_may_alias 1
  14489. _ACEOF
  14490. else
  14491. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14492. $as_echo "no" >&6; }
  14493. fi
  14494. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14495. else
  14496. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14497. /* end confdefs.h. */
  14498. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14499. int
  14500. main ()
  14501. {
  14502. ;
  14503. return 0;
  14504. }
  14505. _ACEOF
  14506. if ac_fn_c_try_compile "$LINENO"; then :
  14507. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14508. $as_echo "yes" >&6; }
  14509. cat >>confdefs.h <<_ACEOF
  14510. #define HAVE_ATTRIBUTE_may_alias 1
  14511. _ACEOF
  14512. else
  14513. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14514. $as_echo "no" >&6; }
  14515. fi
  14516. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14517. fi
  14518. CFLAGS="$saved_CFLAGS"
  14519. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute constructor' support" >&5
  14520. $as_echo_n "checking for compiler 'attribute constructor' support... " >&6; }
  14521. saved_CFLAGS="$CFLAGS"
  14522. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14523. if test "x" = "x"
  14524. then
  14525. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14526. /* end confdefs.h. */
  14527. void __attribute__((constructor)) *test(void *muffin, ...) {return (void *) 0;}
  14528. int
  14529. main ()
  14530. {
  14531. ;
  14532. return 0;
  14533. }
  14534. _ACEOF
  14535. if ac_fn_c_try_compile "$LINENO"; then :
  14536. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14537. $as_echo "yes" >&6; }
  14538. cat >>confdefs.h <<_ACEOF
  14539. #define HAVE_ATTRIBUTE_constructor 1
  14540. _ACEOF
  14541. else
  14542. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14543. $as_echo "no" >&6; }
  14544. fi
  14545. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14546. else
  14547. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14548. /* end confdefs.h. */
  14549. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14550. int
  14551. main ()
  14552. {
  14553. ;
  14554. return 0;
  14555. }
  14556. _ACEOF
  14557. if ac_fn_c_try_compile "$LINENO"; then :
  14558. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14559. $as_echo "yes" >&6; }
  14560. cat >>confdefs.h <<_ACEOF
  14561. #define HAVE_ATTRIBUTE_constructor 1
  14562. _ACEOF
  14563. else
  14564. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14565. $as_echo "no" >&6; }
  14566. fi
  14567. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14568. fi
  14569. CFLAGS="$saved_CFLAGS"
  14570. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler 'attribute destructor' support" >&5
  14571. $as_echo_n "checking for compiler 'attribute destructor' support... " >&6; }
  14572. saved_CFLAGS="$CFLAGS"
  14573. CFLAGS="$CFLAGS -Wall -Wno-unused -Werror"
  14574. if test "x" = "x"
  14575. then
  14576. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14577. /* end confdefs.h. */
  14578. void __attribute__((destructor)) *test(void *muffin, ...) {return (void *) 0;}
  14579. int
  14580. main ()
  14581. {
  14582. ;
  14583. return 0;
  14584. }
  14585. _ACEOF
  14586. if ac_fn_c_try_compile "$LINENO"; then :
  14587. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14588. $as_echo "yes" >&6; }
  14589. cat >>confdefs.h <<_ACEOF
  14590. #define HAVE_ATTRIBUTE_destructor 1
  14591. _ACEOF
  14592. else
  14593. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14594. $as_echo "no" >&6; }
  14595. fi
  14596. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14597. else
  14598. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14599. /* end confdefs.h. */
  14600. void __attribute__(()) *test(void *muffin, ...) {return (void *) 0;}
  14601. int
  14602. main ()
  14603. {
  14604. ;
  14605. return 0;
  14606. }
  14607. _ACEOF
  14608. if ac_fn_c_try_compile "$LINENO"; then :
  14609. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14610. $as_echo "yes" >&6; }
  14611. cat >>confdefs.h <<_ACEOF
  14612. #define HAVE_ATTRIBUTE_destructor 1
  14613. _ACEOF
  14614. else
  14615. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14616. $as_echo "no" >&6; }
  14617. fi
  14618. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14619. fi
  14620. CFLAGS="$saved_CFLAGS"
  14621. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -ffunction-sections support" >&5
  14622. $as_echo_n "checking for -ffunction-sections support... " >&6; }
  14623. saved_CFLAGS="${CFLAGS}"
  14624. CFLAGS="${CFLAGS} -ffunction-sections"
  14625. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14626. /* end confdefs.h. */
  14627. int
  14628. main ()
  14629. {
  14630. int x = 1;
  14631. ;
  14632. return 0;
  14633. }
  14634. _ACEOF
  14635. if ac_fn_c_try_compile "$LINENO"; then :
  14636. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14637. $as_echo "yes" >&6; }
  14638. saved_LDFLAGS="${LDFLAGS}"
  14639. LDFLAGS="${LDFLAGS} -Wl,--gc-sections"
  14640. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for --gc-sections support" >&5
  14641. $as_echo_n "checking for --gc-sections support... " >&6; }
  14642. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14643. /* end confdefs.h. */
  14644. int
  14645. main ()
  14646. {
  14647. int x = 1;
  14648. ;
  14649. return 0;
  14650. }
  14651. _ACEOF
  14652. if ac_fn_c_try_link "$LINENO"; then :
  14653. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14654. $as_echo "yes" >&6; }
  14655. GC_CFLAGS="-ffunction-sections"
  14656. GC_LDFLAGS="-Wl,--gc-sections"
  14657. else
  14658. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14659. $as_echo "no" >&6; }
  14660. fi
  14661. rm -f core conftest.err conftest.$ac_objext \
  14662. conftest$ac_exeext conftest.$ac_ext
  14663. LDFLAGS="${saved_LDFLAGS}"
  14664. else
  14665. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14666. $as_echo "no" >&6; }
  14667. fi
  14668. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14669. CFLAGS="${saved_CFLAGS}"
  14670. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wdeclaration-after-statement support" >&5
  14671. $as_echo_n "checking for -Wdeclaration-after-statement support... " >&6; }
  14672. if $(${CC} -Wdeclaration-after-statement -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14673. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14674. $as_echo "yes" >&6; }
  14675. AST_DECLARATION_AFTER_STATEMENT=-Wdeclaration-after-statement
  14676. else
  14677. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14678. $as_echo "no" >&6; }
  14679. AST_DECLARATION_AFTER_STATEMENT=
  14680. fi
  14681. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wtrampolines support" >&5
  14682. $as_echo_n "checking for -Wtrampolines support... " >&6; }
  14683. if $(${CC} -Wtrampolines -Werror -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14684. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14685. $as_echo "yes" >&6; }
  14686. AST_TRAMPOLINES=-Wtrampolines
  14687. else
  14688. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14689. $as_echo "no" >&6; }
  14690. AST_TRAMPOLINES=
  14691. fi
  14692. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FORTIFY_SOURCE support" >&5
  14693. $as_echo_n "checking for _FORTIFY_SOURCE support... " >&6; }
  14694. if $(${CC} -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14695. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14696. $as_echo "yes" >&6; }
  14697. AST_FORTIFY_SOURCE="-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2"
  14698. else
  14699. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14700. $as_echo "no" >&6; }
  14701. AST_FORTIFY_SOURCE=
  14702. fi
  14703. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fno-strict-overflow" >&5
  14704. $as_echo_n "checking for -fno-strict-overflow... " >&6; }
  14705. if $(${CC} -O2 -fno-strict-overflow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14706. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14707. $as_echo "yes" >&6; }
  14708. AST_NO_STRICT_OVERFLOW=-fno-strict-overflow
  14709. else
  14710. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14711. $as_echo "no" >&6; }
  14712. AST_NO_STRICT_OVERFLOW=
  14713. fi
  14714. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -Wshadow" >&5
  14715. $as_echo_n "checking for -Wshadow... " >&6; }
  14716. if $(${CC} -Wshadow -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14717. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14718. $as_echo "yes" >&6; }
  14719. AST_SHADOW_WARNINGS=-Wshadow
  14720. else
  14721. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14722. $as_echo "no" >&6; }
  14723. AST_SHADOW_WARNINGS=
  14724. fi
  14725. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -march=native support" >&5
  14726. $as_echo_n "checking for -march=native support... " >&6; }
  14727. if $(${CC} -march=native -S -o /dev/null -xc /dev/null > /dev/null 2>&1); then
  14728. if test "${CONFIG_CFLAGS}" = ""; then
  14729. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14730. $as_echo "yes" >&6; }
  14731. AST_NATIVE_ARCH=1
  14732. else
  14733. { $as_echo "$as_me:${as_lineno-$LINENO}: result: user CFLAGS present" >&5
  14734. $as_echo "user CFLAGS present" >&6; }
  14735. AST_NATIVE_ARCH=
  14736. fi
  14737. else
  14738. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14739. $as_echo "no" >&6; }
  14740. AST_NATIVE_ARCH=
  14741. fi
  14742. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14743. /* end confdefs.h. */
  14744. int
  14745. main ()
  14746. {
  14747. #if defined(__clang__)
  14748. choke
  14749. #endif
  14750. ;
  14751. return 0;
  14752. }
  14753. _ACEOF
  14754. if ac_fn_c_try_link "$LINENO"; then :
  14755. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc -fnested-functions" >&5
  14756. $as_echo_n "checking for gcc -fnested-functions... " >&6; }
  14757. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14758. /* end confdefs.h. */
  14759. int
  14760. main ()
  14761. {
  14762. auto void foo(void); void foo(void) {}
  14763. ;
  14764. return 0;
  14765. }
  14766. _ACEOF
  14767. if ac_fn_c_try_compile "$LINENO"; then :
  14768. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14769. $as_echo "no" >&6; }
  14770. AST_NESTED_FUNCTIONS=
  14771. else
  14772. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14773. $as_echo "yes" >&6; }
  14774. AST_NESTED_FUNCTIONS=-fnested-functions
  14775. fi
  14776. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  14777. else
  14778. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clang -fblocks" >&5
  14779. $as_echo_n "checking for clang -fblocks... " >&6; }
  14780. if test "`echo "int main(){return ^{return 42;}();}" | ${CC} -o /dev/null -fblocks -x c - 2>&1`" = ""; then
  14781. AST_CLANG_BLOCKS_LIBS=""
  14782. AST_CLANG_BLOCKS="-Wno-unknown-warning-option -fblocks"
  14783. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14784. $as_echo "yes" >&6; }
  14785. elif test "`echo "int main(){return ^{return 42;}();}" | ${CC} -o /dev/null -fblocks -x c -lBlocksRuntime - 2>&1`" = ""; then
  14786. AST_CLANG_BLOCKS_LIBS="-lBlocksRuntime"
  14787. AST_CLANG_BLOCKS="-fblocks"
  14788. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14789. $as_echo "yes" >&6; }
  14790. else
  14791. as_fn_error $? "\"BlocksRuntime is required for clang\"" "$LINENO" 5
  14792. fi
  14793. fi
  14794. rm -f core conftest.err conftest.$ac_objext \
  14795. conftest$ac_exeext conftest.$ac_ext
  14796. # Check whether --enable-rpath was given.
  14797. if test "${enable_rpath+set}" = set; then :
  14798. enableval=$enable_rpath; case "${enableval}" in
  14799. y|ye|yes) check_rpath=yes ;;
  14800. n|no) check_rpath=no ;;
  14801. *) as_fn_error $? "bad value ${enableval} for --disable-rpath" "$LINENO" 5 ;;
  14802. esac
  14803. else
  14804. check_rpath=yes
  14805. fi
  14806. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use rpath" >&5
  14807. $as_echo_n "checking whether to use rpath... " >&6; }
  14808. AST_RPATH=
  14809. if test "${check_rpath}" != yes; then
  14810. { $as_echo "$as_me:${as_lineno-$LINENO}: result: skipped" >&5
  14811. $as_echo "skipped" >&6; }
  14812. elif test "${prefix}" = /usr || test "${prefix}" = NONE; then
  14813. { $as_echo "$as_me:${as_lineno-$LINENO}: result: not needed" >&5
  14814. $as_echo "not needed" >&6; }
  14815. else
  14816. AST_RPATH="-Wl,-rpath,${libdir}"
  14817. fi
  14818. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysinfo" >&5
  14819. $as_echo_n "checking for sysinfo... " >&6; }
  14820. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14821. /* end confdefs.h. */
  14822. #include <sys/sysinfo.h>
  14823. int
  14824. main ()
  14825. {
  14826. struct sysinfo sys_info; int uptime = sys_info.uptime
  14827. ;
  14828. return 0;
  14829. }
  14830. _ACEOF
  14831. if ac_fn_c_try_link "$LINENO"; then :
  14832. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14833. $as_echo "yes" >&6; }
  14834. $as_echo "#define HAVE_SYSINFO 1" >>confdefs.h
  14835. else
  14836. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14837. $as_echo "no" >&6; }
  14838. fi
  14839. rm -f core conftest.err conftest.$ac_objext \
  14840. conftest$ac_exeext conftest.$ac_ext
  14841. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_ninit" >&5
  14842. $as_echo_n "checking for library containing res_9_ninit... " >&6; }
  14843. if ${ac_cv_search_res_9_ninit+:} false; then :
  14844. $as_echo_n "(cached) " >&6
  14845. else
  14846. ac_func_search_save_LIBS=$LIBS
  14847. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14848. /* end confdefs.h. */
  14849. /* Override any GCC internal prototype to avoid an error.
  14850. Use char because int might match the return type of a GCC
  14851. builtin and then its argument prototype would still apply. */
  14852. #ifdef __cplusplus
  14853. extern "C"
  14854. #endif
  14855. char res_9_ninit ();
  14856. int
  14857. main ()
  14858. {
  14859. return res_9_ninit ();
  14860. ;
  14861. return 0;
  14862. }
  14863. _ACEOF
  14864. for ac_lib in '' resolv; do
  14865. if test -z "$ac_lib"; then
  14866. ac_res="none required"
  14867. else
  14868. ac_res=-l$ac_lib
  14869. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  14870. fi
  14871. if ac_fn_c_try_link "$LINENO"; then :
  14872. ac_cv_search_res_9_ninit=$ac_res
  14873. fi
  14874. rm -f core conftest.err conftest.$ac_objext \
  14875. conftest$ac_exeext
  14876. if ${ac_cv_search_res_9_ninit+:} false; then :
  14877. break
  14878. fi
  14879. done
  14880. if ${ac_cv_search_res_9_ninit+:} false; then :
  14881. else
  14882. ac_cv_search_res_9_ninit=no
  14883. fi
  14884. rm conftest.$ac_ext
  14885. LIBS=$ac_func_search_save_LIBS
  14886. fi
  14887. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_ninit" >&5
  14888. $as_echo "$ac_cv_search_res_9_ninit" >&6; }
  14889. ac_res=$ac_cv_search_res_9_ninit
  14890. if test "$ac_res" != no; then :
  14891. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  14892. fi
  14893. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_ninit" >&5
  14894. $as_echo_n "checking for res_ninit... " >&6; }
  14895. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14896. /* end confdefs.h. */
  14897. #ifdef HAVE_SYS_SOCKET_H
  14898. #include <sys/socket.h>
  14899. #endif
  14900. #ifdef HAVE_NETINET_IN_H
  14901. #include <netinet/in.h>
  14902. #endif
  14903. #ifdef HAVE_ARPA_NAMESER_H
  14904. #include <arpa/nameser.h>
  14905. #endif
  14906. #include <resolv.h>
  14907. int
  14908. main ()
  14909. {
  14910. int foo = res_ninit(NULL);
  14911. ;
  14912. return 0;
  14913. }
  14914. _ACEOF
  14915. if ac_fn_c_try_link "$LINENO"; then :
  14916. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14917. $as_echo "yes" >&6; }
  14918. $as_echo "#define HAVE_RES_NINIT 1" >>confdefs.h
  14919. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_ndestroy" >&5
  14920. $as_echo_n "checking for library containing res_9_ndestroy... " >&6; }
  14921. if ${ac_cv_search_res_9_ndestroy+:} false; then :
  14922. $as_echo_n "(cached) " >&6
  14923. else
  14924. ac_func_search_save_LIBS=$LIBS
  14925. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14926. /* end confdefs.h. */
  14927. /* Override any GCC internal prototype to avoid an error.
  14928. Use char because int might match the return type of a GCC
  14929. builtin and then its argument prototype would still apply. */
  14930. #ifdef __cplusplus
  14931. extern "C"
  14932. #endif
  14933. char res_9_ndestroy ();
  14934. int
  14935. main ()
  14936. {
  14937. return res_9_ndestroy ();
  14938. ;
  14939. return 0;
  14940. }
  14941. _ACEOF
  14942. for ac_lib in '' resolv; do
  14943. if test -z "$ac_lib"; then
  14944. ac_res="none required"
  14945. else
  14946. ac_res=-l$ac_lib
  14947. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  14948. fi
  14949. if ac_fn_c_try_link "$LINENO"; then :
  14950. ac_cv_search_res_9_ndestroy=$ac_res
  14951. fi
  14952. rm -f core conftest.err conftest.$ac_objext \
  14953. conftest$ac_exeext
  14954. if ${ac_cv_search_res_9_ndestroy+:} false; then :
  14955. break
  14956. fi
  14957. done
  14958. if ${ac_cv_search_res_9_ndestroy+:} false; then :
  14959. else
  14960. ac_cv_search_res_9_ndestroy=no
  14961. fi
  14962. rm conftest.$ac_ext
  14963. LIBS=$ac_func_search_save_LIBS
  14964. fi
  14965. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_ndestroy" >&5
  14966. $as_echo "$ac_cv_search_res_9_ndestroy" >&6; }
  14967. ac_res=$ac_cv_search_res_9_ndestroy
  14968. if test "$ac_res" != no; then :
  14969. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  14970. fi
  14971. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_ndestroy" >&5
  14972. $as_echo_n "checking for res_ndestroy... " >&6; }
  14973. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  14974. /* end confdefs.h. */
  14975. #ifdef HAVE_SYS_SOCKET_H
  14976. #include <sys/socket.h>
  14977. #endif
  14978. #ifdef HAVE_NETINET_IN_H
  14979. #include <netinet/in.h>
  14980. #endif
  14981. #ifdef HAVE_ARPA_NAMESER_H
  14982. #include <arpa/nameser.h>
  14983. #endif
  14984. #include <resolv.h>
  14985. int
  14986. main ()
  14987. {
  14988. res_ndestroy(NULL);
  14989. ;
  14990. return 0;
  14991. }
  14992. _ACEOF
  14993. if ac_fn_c_try_link "$LINENO"; then :
  14994. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  14995. $as_echo "yes" >&6; }
  14996. $as_echo "#define HAVE_RES_NDESTROY 1" >>confdefs.h
  14997. else
  14998. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  14999. $as_echo "no" >&6; }
  15000. fi
  15001. rm -f core conftest.err conftest.$ac_objext \
  15002. conftest$ac_exeext conftest.$ac_ext
  15003. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_close" >&5
  15004. $as_echo_n "checking for library containing res_9_close... " >&6; }
  15005. if ${ac_cv_search_res_9_close+:} false; then :
  15006. $as_echo_n "(cached) " >&6
  15007. else
  15008. ac_func_search_save_LIBS=$LIBS
  15009. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15010. /* end confdefs.h. */
  15011. /* Override any GCC internal prototype to avoid an error.
  15012. Use char because int might match the return type of a GCC
  15013. builtin and then its argument prototype would still apply. */
  15014. #ifdef __cplusplus
  15015. extern "C"
  15016. #endif
  15017. char res_9_close ();
  15018. int
  15019. main ()
  15020. {
  15021. return res_9_close ();
  15022. ;
  15023. return 0;
  15024. }
  15025. _ACEOF
  15026. for ac_lib in '' resolv; do
  15027. if test -z "$ac_lib"; then
  15028. ac_res="none required"
  15029. else
  15030. ac_res=-l$ac_lib
  15031. LIBS="-l$ac_lib $ac_func_search_save_LIBS"
  15032. fi
  15033. if ac_fn_c_try_link "$LINENO"; then :
  15034. ac_cv_search_res_9_close=$ac_res
  15035. fi
  15036. rm -f core conftest.err conftest.$ac_objext \
  15037. conftest$ac_exeext
  15038. if ${ac_cv_search_res_9_close+:} false; then :
  15039. break
  15040. fi
  15041. done
  15042. if ${ac_cv_search_res_9_close+:} false; then :
  15043. else
  15044. ac_cv_search_res_9_close=no
  15045. fi
  15046. rm conftest.$ac_ext
  15047. LIBS=$ac_func_search_save_LIBS
  15048. fi
  15049. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_close" >&5
  15050. $as_echo "$ac_cv_search_res_9_close" >&6; }
  15051. ac_res=$ac_cv_search_res_9_close
  15052. if test "$ac_res" != no; then :
  15053. test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
  15054. fi
  15055. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_close" >&5
  15056. $as_echo_n "checking for res_close... " >&6; }
  15057. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15058. /* end confdefs.h. */
  15059. #ifdef HAVE_SYS_SOCKET_H
  15060. #include <sys/socket.h>
  15061. #endif
  15062. #ifdef HAVE_NETINET_IN_H
  15063. #include <netinet/in.h>
  15064. #endif
  15065. #ifdef HAVE_ARPA_NAMESER_H
  15066. #include <arpa/nameser.h>
  15067. #endif
  15068. #include <resolv.h>
  15069. int
  15070. main ()
  15071. {
  15072. res_close();
  15073. ;
  15074. return 0;
  15075. }
  15076. _ACEOF
  15077. if ac_fn_c_try_link "$LINENO"; then :
  15078. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15079. $as_echo "yes" >&6; }
  15080. $as_echo "#define HAVE_RES_CLOSE 1" >>confdefs.h
  15081. else
  15082. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15083. $as_echo "no" >&6; }
  15084. fi
  15085. rm -f core conftest.err conftest.$ac_objext \
  15086. conftest$ac_exeext conftest.$ac_ext
  15087. else
  15088. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15089. $as_echo "no" >&6; }
  15090. fi
  15091. rm -f core conftest.err conftest.$ac_objext \
  15092. conftest$ac_exeext conftest.$ac_ext
  15093. if test "x${PBX_GLOB_NOMAGIC}" != "x1"; then
  15094. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLOB_NOMAGIC in glob.h" >&5
  15095. $as_echo_n "checking for GLOB_NOMAGIC in glob.h... " >&6; }
  15096. saved_cppflags="${CPPFLAGS}"
  15097. if test "x${GLOB_NOMAGIC_DIR}" != "x"; then
  15098. GLOB_NOMAGIC_INCLUDE="-I${GLOB_NOMAGIC_DIR}/include"
  15099. fi
  15100. CPPFLAGS="${CPPFLAGS} ${GLOB_NOMAGIC_INCLUDE}"
  15101. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15102. /* end confdefs.h. */
  15103. #include <glob.h>
  15104. int
  15105. main ()
  15106. {
  15107. #if defined(GLOB_NOMAGIC)
  15108. int foo = 0;
  15109. #else
  15110. int foo = bar;
  15111. #endif
  15112. 0
  15113. ;
  15114. return 0;
  15115. }
  15116. _ACEOF
  15117. if ac_fn_c_try_compile "$LINENO"; then :
  15118. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15119. $as_echo "yes" >&6; }
  15120. PBX_GLOB_NOMAGIC=1
  15121. $as_echo "#define HAVE_GLOB_NOMAGIC 1" >>confdefs.h
  15122. else
  15123. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15124. $as_echo "no" >&6; }
  15125. fi
  15126. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15127. CPPFLAGS="${saved_cppflags}"
  15128. fi
  15129. if test "x${PBX_GLOB_BRACE}" != "x1"; then
  15130. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLOB_BRACE in glob.h" >&5
  15131. $as_echo_n "checking for GLOB_BRACE in glob.h... " >&6; }
  15132. saved_cppflags="${CPPFLAGS}"
  15133. if test "x${GLOB_BRACE_DIR}" != "x"; then
  15134. GLOB_BRACE_INCLUDE="-I${GLOB_BRACE_DIR}/include"
  15135. fi
  15136. CPPFLAGS="${CPPFLAGS} ${GLOB_BRACE_INCLUDE}"
  15137. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15138. /* end confdefs.h. */
  15139. #include <glob.h>
  15140. int
  15141. main ()
  15142. {
  15143. #if defined(GLOB_BRACE)
  15144. int foo = 0;
  15145. #else
  15146. int foo = bar;
  15147. #endif
  15148. 0
  15149. ;
  15150. return 0;
  15151. }
  15152. _ACEOF
  15153. if ac_fn_c_try_compile "$LINENO"; then :
  15154. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15155. $as_echo "yes" >&6; }
  15156. PBX_GLOB_BRACE=1
  15157. $as_echo "#define HAVE_GLOB_BRACE 1" >>confdefs.h
  15158. else
  15159. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15160. $as_echo "no" >&6; }
  15161. fi
  15162. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15163. CPPFLAGS="${saved_cppflags}"
  15164. fi
  15165. if test "x${PBX_RTLD_NOLOAD}" != "x1"; then
  15166. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RTLD_NOLOAD in dlfcn.h" >&5
  15167. $as_echo_n "checking for RTLD_NOLOAD in dlfcn.h... " >&6; }
  15168. saved_cppflags="${CPPFLAGS}"
  15169. if test "x${RTLD_NOLOAD_DIR}" != "x"; then
  15170. RTLD_NOLOAD_INCLUDE="-I${RTLD_NOLOAD_DIR}/include"
  15171. fi
  15172. CPPFLAGS="${CPPFLAGS} ${RTLD_NOLOAD_INCLUDE}"
  15173. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15174. /* end confdefs.h. */
  15175. #include <dlfcn.h>
  15176. int
  15177. main ()
  15178. {
  15179. #if defined(RTLD_NOLOAD)
  15180. int foo = 0;
  15181. #else
  15182. int foo = bar;
  15183. #endif
  15184. 0
  15185. ;
  15186. return 0;
  15187. }
  15188. _ACEOF
  15189. if ac_fn_c_try_compile "$LINENO"; then :
  15190. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15191. $as_echo "yes" >&6; }
  15192. PBX_RTLD_NOLOAD=1
  15193. $as_echo "#define HAVE_RTLD_NOLOAD 1" >>confdefs.h
  15194. else
  15195. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15196. $as_echo "no" >&6; }
  15197. fi
  15198. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15199. CPPFLAGS="${saved_cppflags}"
  15200. fi
  15201. if test "x${PBX_IP_MTU_DISCOVER}" != "x1"; then
  15202. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IP_MTU_DISCOVER in netinet/in.h" >&5
  15203. $as_echo_n "checking for IP_MTU_DISCOVER in netinet/in.h... " >&6; }
  15204. saved_cppflags="${CPPFLAGS}"
  15205. if test "x${IP_MTU_DISCOVER_DIR}" != "x"; then
  15206. IP_MTU_DISCOVER_INCLUDE="-I${IP_MTU_DISCOVER_DIR}/include"
  15207. fi
  15208. CPPFLAGS="${CPPFLAGS} ${IP_MTU_DISCOVER_INCLUDE}"
  15209. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15210. /* end confdefs.h. */
  15211. #include <netinet/in.h>
  15212. int
  15213. main ()
  15214. {
  15215. #if defined(IP_MTU_DISCOVER)
  15216. int foo = 0;
  15217. #else
  15218. int foo = bar;
  15219. #endif
  15220. 0
  15221. ;
  15222. return 0;
  15223. }
  15224. _ACEOF
  15225. if ac_fn_c_try_compile "$LINENO"; then :
  15226. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15227. $as_echo "yes" >&6; }
  15228. PBX_IP_MTU_DISCOVER=1
  15229. $as_echo "#define HAVE_IP_MTU_DISCOVER 1" >>confdefs.h
  15230. else
  15231. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15232. $as_echo "no" >&6; }
  15233. fi
  15234. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  15235. CPPFLAGS="${saved_cppflags}"
  15236. fi
  15237. ac_fn_c_check_header_mongrel "$LINENO" "libkern/OSAtomic.h" "ac_cv_header_libkern_OSAtomic_h" "$ac_includes_default"
  15238. if test "x$ac_cv_header_libkern_OSAtomic_h" = xyes; then :
  15239. cat >>confdefs.h <<_ACEOF
  15240. #define HAVE_OSX_ATOMICS 1
  15241. _ACEOF
  15242. fi
  15243. # The cast to long int works around a bug in the HP C Compiler
  15244. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15245. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15246. # This bug is HP SR number 8606223364.
  15247. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
  15248. $as_echo_n "checking size of int... " >&6; }
  15249. if ${ac_cv_sizeof_int+:} false; then :
  15250. $as_echo_n "(cached) " >&6
  15251. else
  15252. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then :
  15253. else
  15254. if test "$ac_cv_type_int" = yes; then
  15255. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15256. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15257. as_fn_error 77 "cannot compute sizeof (int)
  15258. See \`config.log' for more details" "$LINENO" 5; }
  15259. else
  15260. ac_cv_sizeof_int=0
  15261. fi
  15262. fi
  15263. fi
  15264. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
  15265. $as_echo "$ac_cv_sizeof_int" >&6; }
  15266. cat >>confdefs.h <<_ACEOF
  15267. #define SIZEOF_INT $ac_cv_sizeof_int
  15268. _ACEOF
  15269. # The cast to long int works around a bug in the HP C Compiler
  15270. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15271. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15272. # This bug is HP SR number 8606223364.
  15273. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
  15274. $as_echo_n "checking size of long... " >&6; }
  15275. if ${ac_cv_sizeof_long+:} false; then :
  15276. $as_echo_n "(cached) " >&6
  15277. else
  15278. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
  15279. else
  15280. if test "$ac_cv_type_long" = yes; then
  15281. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15282. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15283. as_fn_error 77 "cannot compute sizeof (long)
  15284. See \`config.log' for more details" "$LINENO" 5; }
  15285. else
  15286. ac_cv_sizeof_long=0
  15287. fi
  15288. fi
  15289. fi
  15290. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
  15291. $as_echo "$ac_cv_sizeof_long" >&6; }
  15292. cat >>confdefs.h <<_ACEOF
  15293. #define SIZEOF_LONG $ac_cv_sizeof_long
  15294. _ACEOF
  15295. # The cast to long int works around a bug in the HP C Compiler
  15296. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15297. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15298. # This bug is HP SR number 8606223364.
  15299. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
  15300. $as_echo_n "checking size of long long... " >&6; }
  15301. if ${ac_cv_sizeof_long_long+:} false; then :
  15302. $as_echo_n "(cached) " >&6
  15303. else
  15304. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
  15305. else
  15306. if test "$ac_cv_type_long_long" = yes; then
  15307. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15308. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15309. as_fn_error 77 "cannot compute sizeof (long long)
  15310. See \`config.log' for more details" "$LINENO" 5; }
  15311. else
  15312. ac_cv_sizeof_long_long=0
  15313. fi
  15314. fi
  15315. fi
  15316. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
  15317. $as_echo "$ac_cv_sizeof_long_long" >&6; }
  15318. cat >>confdefs.h <<_ACEOF
  15319. #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
  15320. _ACEOF
  15321. # The cast to long int works around a bug in the HP C Compiler
  15322. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15323. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15324. # This bug is HP SR number 8606223364.
  15325. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5
  15326. $as_echo_n "checking size of char *... " >&6; }
  15327. if ${ac_cv_sizeof_char_p+:} false; then :
  15328. $as_echo_n "(cached) " >&6
  15329. else
  15330. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then :
  15331. else
  15332. if test "$ac_cv_type_char_p" = yes; then
  15333. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15334. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15335. as_fn_error 77 "cannot compute sizeof (char *)
  15336. See \`config.log' for more details" "$LINENO" 5; }
  15337. else
  15338. ac_cv_sizeof_char_p=0
  15339. fi
  15340. fi
  15341. fi
  15342. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5
  15343. $as_echo "$ac_cv_sizeof_char_p" >&6; }
  15344. cat >>confdefs.h <<_ACEOF
  15345. #define SIZEOF_CHAR_P $ac_cv_sizeof_char_p
  15346. _ACEOF
  15347. # The cast to long int works around a bug in the HP C Compiler
  15348. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15349. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15350. # This bug is HP SR number 8606223364.
  15351. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
  15352. $as_echo_n "checking size of long... " >&6; }
  15353. if ${ac_cv_sizeof_long+:} false; then :
  15354. $as_echo_n "(cached) " >&6
  15355. else
  15356. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
  15357. else
  15358. if test "$ac_cv_type_long" = yes; then
  15359. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15360. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15361. as_fn_error 77 "cannot compute sizeof (long)
  15362. See \`config.log' for more details" "$LINENO" 5; }
  15363. else
  15364. ac_cv_sizeof_long=0
  15365. fi
  15366. fi
  15367. fi
  15368. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
  15369. $as_echo "$ac_cv_sizeof_long" >&6; }
  15370. cat >>confdefs.h <<_ACEOF
  15371. #define SIZEOF_LONG $ac_cv_sizeof_long
  15372. _ACEOF
  15373. # The cast to long int works around a bug in the HP C Compiler
  15374. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15375. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15376. # This bug is HP SR number 8606223364.
  15377. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
  15378. $as_echo_n "checking size of long long... " >&6; }
  15379. if ${ac_cv_sizeof_long_long+:} false; then :
  15380. $as_echo_n "(cached) " >&6
  15381. else
  15382. if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
  15383. else
  15384. if test "$ac_cv_type_long_long" = yes; then
  15385. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15386. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15387. as_fn_error 77 "cannot compute sizeof (long long)
  15388. See \`config.log' for more details" "$LINENO" 5; }
  15389. else
  15390. ac_cv_sizeof_long_long=0
  15391. fi
  15392. fi
  15393. fi
  15394. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
  15395. $as_echo "$ac_cv_sizeof_long_long" >&6; }
  15396. cat >>confdefs.h <<_ACEOF
  15397. #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
  15398. _ACEOF
  15399. if ac_fn_c_compute_int "$LINENO" "sizeof(foo.fds_bits[0])" "ac_cv_sizeof_fd_set_fds_bits" "$ac_includes_default
  15400. fd_set foo;"; then :
  15401. fi
  15402. # This doesn't actually work; what it does is to use the variable set in the
  15403. # previous test as a cached value to set the right output variables.
  15404. # The cast to long int works around a bug in the HP C Compiler
  15405. # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
  15406. # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
  15407. # This bug is HP SR number 8606223364.
  15408. { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of fd_set.fds_bits" >&5
  15409. $as_echo_n "checking size of fd_set.fds_bits... " >&6; }
  15410. if ${ac_cv_sizeof_fd_set_fds_bits+:} false; then :
  15411. $as_echo_n "(cached) " >&6
  15412. else
  15413. 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 :
  15414. else
  15415. if test "$ac_cv_type_fd_set_fds_bits" = yes; then
  15416. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  15417. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  15418. as_fn_error 77 "cannot compute sizeof (fd_set.fds_bits)
  15419. See \`config.log' for more details" "$LINENO" 5; }
  15420. else
  15421. ac_cv_sizeof_fd_set_fds_bits=0
  15422. fi
  15423. fi
  15424. fi
  15425. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_fd_set_fds_bits" >&5
  15426. $as_echo "$ac_cv_sizeof_fd_set_fds_bits" >&6; }
  15427. cat >>confdefs.h <<_ACEOF
  15428. #define SIZEOF_FD_SET_FDS_BITS $ac_cv_sizeof_fd_set_fds_bits
  15429. _ACEOF
  15430. # Set a type compatible with the previous. We cannot just use a generic type
  15431. # for these bits, because on big-endian systems, the bits won't match up
  15432. # correctly if the size is wrong.
  15433. if test $ac_cv_sizeof_int = $ac_cv_sizeof_fd_set_fds_bits; then
  15434. $as_echo "#define TYPEOF_FD_SET_FDS_BITS int" >>confdefs.h
  15435. else if test $ac_cv_sizeof_long = $ac_cv_sizeof_fd_set_fds_bits; then
  15436. $as_echo "#define TYPEOF_FD_SET_FDS_BITS long" >>confdefs.h
  15437. else if test $ac_cv_sizeof_long_long = $ac_cv_sizeof_fd_set_fds_bits; then
  15438. $as_echo "#define TYPEOF_FD_SET_FDS_BITS long long" >>confdefs.h
  15439. fi ; fi ; fi
  15440. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dladdr in dlfcn.h" >&5
  15441. $as_echo_n "checking for dladdr in dlfcn.h... " >&6; }
  15442. PBX_DLADDR=0
  15443. old_LIBS=${LIBS}
  15444. LIBS="${LIBS} -ldl"
  15445. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15446. /* end confdefs.h. */
  15447. #define _GNU_SOURCE 1
  15448. #include <dlfcn.h>
  15449. int
  15450. main ()
  15451. {
  15452. dladdr((void *)0, (void *)0)
  15453. ;
  15454. return 0;
  15455. }
  15456. _ACEOF
  15457. if ac_fn_c_try_link "$LINENO"; then :
  15458. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15459. $as_echo "yes" >&6; }
  15460. PBX_DLADDR=1
  15461. $as_echo "#define HAVE_DLADDR 1" >>confdefs.h
  15462. else
  15463. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15464. $as_echo "no" >&6; }
  15465. fi
  15466. rm -f core conftest.err conftest.$ac_objext \
  15467. conftest$ac_exeext conftest.$ac_ext
  15468. LIBS=${old_LIBS}
  15469. # PKGCONFIG is used in later tests
  15470. if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
  15471. if test -n "$ac_tool_prefix"; then
  15472. # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
  15473. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
  15474. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  15475. $as_echo_n "checking for $ac_word... " >&6; }
  15476. if ${ac_cv_path_PKG_CONFIG+:} false; then :
  15477. $as_echo_n "(cached) " >&6
  15478. else
  15479. case $PKG_CONFIG in
  15480. [\\/]* | ?:[\\/]*)
  15481. ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
  15482. ;;
  15483. *)
  15484. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  15485. for as_dir in $PATH
  15486. do
  15487. IFS=$as_save_IFS
  15488. test -z "$as_dir" && as_dir=.
  15489. for ac_exec_ext in '' $ac_executable_extensions; do
  15490. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  15491. ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  15492. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  15493. break 2
  15494. fi
  15495. done
  15496. done
  15497. IFS=$as_save_IFS
  15498. ;;
  15499. esac
  15500. fi
  15501. PKG_CONFIG=$ac_cv_path_PKG_CONFIG
  15502. if test -n "$PKG_CONFIG"; then
  15503. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
  15504. $as_echo "$PKG_CONFIG" >&6; }
  15505. else
  15506. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15507. $as_echo "no" >&6; }
  15508. fi
  15509. fi
  15510. if test -z "$ac_cv_path_PKG_CONFIG"; then
  15511. ac_pt_PKG_CONFIG=$PKG_CONFIG
  15512. # Extract the first word of "pkg-config", so it can be a program name with args.
  15513. set dummy pkg-config; ac_word=$2
  15514. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  15515. $as_echo_n "checking for $ac_word... " >&6; }
  15516. if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
  15517. $as_echo_n "(cached) " >&6
  15518. else
  15519. case $ac_pt_PKG_CONFIG in
  15520. [\\/]* | ?:[\\/]*)
  15521. ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
  15522. ;;
  15523. *)
  15524. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  15525. for as_dir in $PATH
  15526. do
  15527. IFS=$as_save_IFS
  15528. test -z "$as_dir" && as_dir=.
  15529. for ac_exec_ext in '' $ac_executable_extensions; do
  15530. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  15531. ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  15532. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  15533. break 2
  15534. fi
  15535. done
  15536. done
  15537. IFS=$as_save_IFS
  15538. ;;
  15539. esac
  15540. fi
  15541. ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
  15542. if test -n "$ac_pt_PKG_CONFIG"; then
  15543. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
  15544. $as_echo "$ac_pt_PKG_CONFIG" >&6; }
  15545. else
  15546. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15547. $as_echo "no" >&6; }
  15548. fi
  15549. if test "x$ac_pt_PKG_CONFIG" = x; then
  15550. PKG_CONFIG=""
  15551. else
  15552. case $cross_compiling:$ac_tool_warned in
  15553. yes:)
  15554. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  15555. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  15556. ac_tool_warned=yes ;;
  15557. esac
  15558. PKG_CONFIG=$ac_pt_PKG_CONFIG
  15559. fi
  15560. else
  15561. PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
  15562. fi
  15563. fi
  15564. if test -n "$PKG_CONFIG"; then
  15565. _pkg_min_version=0.9.0
  15566. { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
  15567. $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
  15568. if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
  15569. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  15570. $as_echo "yes" >&6; }
  15571. else
  15572. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  15573. $as_echo "no" >&6; }
  15574. PKG_CONFIG=""
  15575. fi
  15576. fi
  15577. # do the package library checks now
  15578. if test "x${PBX_ALSA}" != "x1" -a "${USE_ALSA}" != "no"; then
  15579. pbxlibdir=""
  15580. # if --with-ALSA=DIR has been specified, use it.
  15581. if test "x${ALSA_DIR}" != "x"; then
  15582. if test -d ${ALSA_DIR}/lib; then
  15583. pbxlibdir="-L${ALSA_DIR}/lib"
  15584. else
  15585. pbxlibdir="-L${ALSA_DIR}"
  15586. fi
  15587. fi
  15588. pbxfuncname="snd_spcm_init"
  15589. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15590. AST_ALSA_FOUND=yes
  15591. else
  15592. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15593. CFLAGS="${CFLAGS} "
  15594. as_ac_Lib=`$as_echo "ac_cv_lib_asound_${pbxfuncname}" | $as_tr_sh`
  15595. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lasound" >&5
  15596. $as_echo_n "checking for ${pbxfuncname} in -lasound... " >&6; }
  15597. if eval \${$as_ac_Lib+:} false; then :
  15598. $as_echo_n "(cached) " >&6
  15599. else
  15600. ac_check_lib_save_LIBS=$LIBS
  15601. LIBS="-lasound ${pbxlibdir} -lm -ldl $LIBS"
  15602. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15603. /* end confdefs.h. */
  15604. /* Override any GCC internal prototype to avoid an error.
  15605. Use char because int might match the return type of a GCC
  15606. builtin and then its argument prototype would still apply. */
  15607. #ifdef __cplusplus
  15608. extern "C"
  15609. #endif
  15610. char ${pbxfuncname} ();
  15611. int
  15612. main ()
  15613. {
  15614. return ${pbxfuncname} ();
  15615. ;
  15616. return 0;
  15617. }
  15618. _ACEOF
  15619. if ac_fn_c_try_link "$LINENO"; then :
  15620. eval "$as_ac_Lib=yes"
  15621. else
  15622. eval "$as_ac_Lib=no"
  15623. fi
  15624. rm -f core conftest.err conftest.$ac_objext \
  15625. conftest$ac_exeext conftest.$ac_ext
  15626. LIBS=$ac_check_lib_save_LIBS
  15627. fi
  15628. eval ac_res=\$$as_ac_Lib
  15629. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15630. $as_echo "$ac_res" >&6; }
  15631. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15632. AST_ALSA_FOUND=yes
  15633. else
  15634. AST_ALSA_FOUND=no
  15635. fi
  15636. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15637. fi
  15638. # now check for the header.
  15639. if test "${AST_ALSA_FOUND}" = "yes"; then
  15640. ALSA_LIB="${pbxlibdir} -lasound -lm -ldl"
  15641. # if --with-ALSA=DIR has been specified, use it.
  15642. if test "x${ALSA_DIR}" != "x"; then
  15643. ALSA_INCLUDE="-I${ALSA_DIR}/include"
  15644. fi
  15645. ALSA_INCLUDE="${ALSA_INCLUDE} "
  15646. if test "xalsa/asoundlib.h" = "x" ; then # no header, assume found
  15647. ALSA_HEADER_FOUND="1"
  15648. else # check for the header
  15649. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15650. CPPFLAGS="${CPPFLAGS} ${ALSA_INCLUDE}"
  15651. ac_fn_c_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
  15652. if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
  15653. ALSA_HEADER_FOUND=1
  15654. else
  15655. ALSA_HEADER_FOUND=0
  15656. fi
  15657. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15658. fi
  15659. if test "x${ALSA_HEADER_FOUND}" = "x0" ; then
  15660. ALSA_LIB=""
  15661. ALSA_INCLUDE=""
  15662. else
  15663. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15664. ALSA_LIB=""
  15665. fi
  15666. PBX_ALSA=1
  15667. cat >>confdefs.h <<_ACEOF
  15668. #define HAVE_ALSA 1
  15669. _ACEOF
  15670. fi
  15671. fi
  15672. fi
  15673. if test "x${PBX_BFD}" != "x1" -a "${USE_BFD}" != "no"; then
  15674. pbxlibdir=""
  15675. # if --with-BFD=DIR has been specified, use it.
  15676. if test "x${BFD_DIR}" != "x"; then
  15677. if test -d ${BFD_DIR}/lib; then
  15678. pbxlibdir="-L${BFD_DIR}/lib"
  15679. else
  15680. pbxlibdir="-L${BFD_DIR}"
  15681. fi
  15682. fi
  15683. pbxfuncname="bfd_openr"
  15684. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15685. AST_BFD_FOUND=yes
  15686. else
  15687. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15688. CFLAGS="${CFLAGS} "
  15689. as_ac_Lib=`$as_echo "ac_cv_lib_bfd_${pbxfuncname}" | $as_tr_sh`
  15690. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbfd" >&5
  15691. $as_echo_n "checking for ${pbxfuncname} in -lbfd... " >&6; }
  15692. if eval \${$as_ac_Lib+:} false; then :
  15693. $as_echo_n "(cached) " >&6
  15694. else
  15695. ac_check_lib_save_LIBS=$LIBS
  15696. LIBS="-lbfd ${pbxlibdir} $LIBS"
  15697. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15698. /* end confdefs.h. */
  15699. /* Override any GCC internal prototype to avoid an error.
  15700. Use char because int might match the return type of a GCC
  15701. builtin and then its argument prototype would still apply. */
  15702. #ifdef __cplusplus
  15703. extern "C"
  15704. #endif
  15705. char ${pbxfuncname} ();
  15706. int
  15707. main ()
  15708. {
  15709. return ${pbxfuncname} ();
  15710. ;
  15711. return 0;
  15712. }
  15713. _ACEOF
  15714. if ac_fn_c_try_link "$LINENO"; then :
  15715. eval "$as_ac_Lib=yes"
  15716. else
  15717. eval "$as_ac_Lib=no"
  15718. fi
  15719. rm -f core conftest.err conftest.$ac_objext \
  15720. conftest$ac_exeext conftest.$ac_ext
  15721. LIBS=$ac_check_lib_save_LIBS
  15722. fi
  15723. eval ac_res=\$$as_ac_Lib
  15724. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15725. $as_echo "$ac_res" >&6; }
  15726. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15727. AST_BFD_FOUND=yes
  15728. else
  15729. AST_BFD_FOUND=no
  15730. fi
  15731. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15732. fi
  15733. # now check for the header.
  15734. if test "${AST_BFD_FOUND}" = "yes"; then
  15735. BFD_LIB="${pbxlibdir} -lbfd "
  15736. # if --with-BFD=DIR has been specified, use it.
  15737. if test "x${BFD_DIR}" != "x"; then
  15738. BFD_INCLUDE="-I${BFD_DIR}/include"
  15739. fi
  15740. BFD_INCLUDE="${BFD_INCLUDE} "
  15741. if test "xbfd.h" = "x" ; then # no header, assume found
  15742. BFD_HEADER_FOUND="1"
  15743. else # check for the header
  15744. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15745. CPPFLAGS="${CPPFLAGS} ${BFD_INCLUDE}"
  15746. ac_fn_c_check_header_mongrel "$LINENO" "bfd.h" "ac_cv_header_bfd_h" "$ac_includes_default"
  15747. if test "x$ac_cv_header_bfd_h" = xyes; then :
  15748. BFD_HEADER_FOUND=1
  15749. else
  15750. BFD_HEADER_FOUND=0
  15751. fi
  15752. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15753. fi
  15754. if test "x${BFD_HEADER_FOUND}" = "x0" ; then
  15755. BFD_LIB=""
  15756. BFD_INCLUDE=""
  15757. else
  15758. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15759. BFD_LIB=""
  15760. fi
  15761. PBX_BFD=1
  15762. cat >>confdefs.h <<_ACEOF
  15763. #define HAVE_BFD 1
  15764. _ACEOF
  15765. fi
  15766. fi
  15767. fi
  15768. if test "${PBX_BFD}" = "0"; then
  15769. # Fedora/RedHat/CentOS require extra libraries
  15770. if test "x${PBX_BFD}" != "x1" -a "${USE_BFD}" != "no"; then
  15771. pbxlibdir=""
  15772. # if --with-BFD=DIR has been specified, use it.
  15773. if test "x${BFD_DIR}" != "x"; then
  15774. if test -d ${BFD_DIR}/lib; then
  15775. pbxlibdir="-L${BFD_DIR}/lib"
  15776. else
  15777. pbxlibdir="-L${BFD_DIR}"
  15778. fi
  15779. fi
  15780. pbxfuncname="bfd_check_format"
  15781. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15782. AST_BFD_FOUND=yes
  15783. else
  15784. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15785. CFLAGS="${CFLAGS} "
  15786. as_ac_Lib=`$as_echo "ac_cv_lib_bfd_${pbxfuncname}" | $as_tr_sh`
  15787. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbfd" >&5
  15788. $as_echo_n "checking for ${pbxfuncname} in -lbfd... " >&6; }
  15789. if eval \${$as_ac_Lib+:} false; then :
  15790. $as_echo_n "(cached) " >&6
  15791. else
  15792. ac_check_lib_save_LIBS=$LIBS
  15793. LIBS="-lbfd ${pbxlibdir} -ldl -liberty $LIBS"
  15794. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15795. /* end confdefs.h. */
  15796. /* Override any GCC internal prototype to avoid an error.
  15797. Use char because int might match the return type of a GCC
  15798. builtin and then its argument prototype would still apply. */
  15799. #ifdef __cplusplus
  15800. extern "C"
  15801. #endif
  15802. char ${pbxfuncname} ();
  15803. int
  15804. main ()
  15805. {
  15806. return ${pbxfuncname} ();
  15807. ;
  15808. return 0;
  15809. }
  15810. _ACEOF
  15811. if ac_fn_c_try_link "$LINENO"; then :
  15812. eval "$as_ac_Lib=yes"
  15813. else
  15814. eval "$as_ac_Lib=no"
  15815. fi
  15816. rm -f core conftest.err conftest.$ac_objext \
  15817. conftest$ac_exeext conftest.$ac_ext
  15818. LIBS=$ac_check_lib_save_LIBS
  15819. fi
  15820. eval ac_res=\$$as_ac_Lib
  15821. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15822. $as_echo "$ac_res" >&6; }
  15823. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15824. AST_BFD_FOUND=yes
  15825. else
  15826. AST_BFD_FOUND=no
  15827. fi
  15828. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15829. fi
  15830. # now check for the header.
  15831. if test "${AST_BFD_FOUND}" = "yes"; then
  15832. BFD_LIB="${pbxlibdir} -lbfd -ldl -liberty"
  15833. # if --with-BFD=DIR has been specified, use it.
  15834. if test "x${BFD_DIR}" != "x"; then
  15835. BFD_INCLUDE="-I${BFD_DIR}/include"
  15836. fi
  15837. BFD_INCLUDE="${BFD_INCLUDE} "
  15838. if test "xbfd.h" = "x" ; then # no header, assume found
  15839. BFD_HEADER_FOUND="1"
  15840. else # check for the header
  15841. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15842. CPPFLAGS="${CPPFLAGS} ${BFD_INCLUDE}"
  15843. ac_fn_c_check_header_mongrel "$LINENO" "bfd.h" "ac_cv_header_bfd_h" "$ac_includes_default"
  15844. if test "x$ac_cv_header_bfd_h" = xyes; then :
  15845. BFD_HEADER_FOUND=1
  15846. else
  15847. BFD_HEADER_FOUND=0
  15848. fi
  15849. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15850. fi
  15851. if test "x${BFD_HEADER_FOUND}" = "x0" ; then
  15852. BFD_LIB=""
  15853. BFD_INCLUDE=""
  15854. else
  15855. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15856. BFD_LIB=""
  15857. fi
  15858. PBX_BFD=1
  15859. cat >>confdefs.h <<_ACEOF
  15860. #define HAVE_BFD 1
  15861. _ACEOF
  15862. fi
  15863. fi
  15864. fi
  15865. fi
  15866. if test "${PBX_BFD}" = "0"; then
  15867. # openSUSE requires -lz
  15868. if test "x${PBX_BFD}" != "x1" -a "${USE_BFD}" != "no"; then
  15869. pbxlibdir=""
  15870. # if --with-BFD=DIR has been specified, use it.
  15871. if test "x${BFD_DIR}" != "x"; then
  15872. if test -d ${BFD_DIR}/lib; then
  15873. pbxlibdir="-L${BFD_DIR}/lib"
  15874. else
  15875. pbxlibdir="-L${BFD_DIR}"
  15876. fi
  15877. fi
  15878. pbxfuncname="bfd_check_format"
  15879. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15880. AST_BFD_FOUND=yes
  15881. else
  15882. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15883. CFLAGS="${CFLAGS} "
  15884. as_ac_Lib=`$as_echo "ac_cv_lib_bfd_${pbxfuncname}" | $as_tr_sh`
  15885. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbfd" >&5
  15886. $as_echo_n "checking for ${pbxfuncname} in -lbfd... " >&6; }
  15887. if eval \${$as_ac_Lib+:} false; then :
  15888. $as_echo_n "(cached) " >&6
  15889. else
  15890. ac_check_lib_save_LIBS=$LIBS
  15891. LIBS="-lbfd ${pbxlibdir} -ldl -liberty -lz $LIBS"
  15892. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15893. /* end confdefs.h. */
  15894. /* Override any GCC internal prototype to avoid an error.
  15895. Use char because int might match the return type of a GCC
  15896. builtin and then its argument prototype would still apply. */
  15897. #ifdef __cplusplus
  15898. extern "C"
  15899. #endif
  15900. char ${pbxfuncname} ();
  15901. int
  15902. main ()
  15903. {
  15904. return ${pbxfuncname} ();
  15905. ;
  15906. return 0;
  15907. }
  15908. _ACEOF
  15909. if ac_fn_c_try_link "$LINENO"; then :
  15910. eval "$as_ac_Lib=yes"
  15911. else
  15912. eval "$as_ac_Lib=no"
  15913. fi
  15914. rm -f core conftest.err conftest.$ac_objext \
  15915. conftest$ac_exeext conftest.$ac_ext
  15916. LIBS=$ac_check_lib_save_LIBS
  15917. fi
  15918. eval ac_res=\$$as_ac_Lib
  15919. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  15920. $as_echo "$ac_res" >&6; }
  15921. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  15922. AST_BFD_FOUND=yes
  15923. else
  15924. AST_BFD_FOUND=no
  15925. fi
  15926. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  15927. fi
  15928. # now check for the header.
  15929. if test "${AST_BFD_FOUND}" = "yes"; then
  15930. BFD_LIB="${pbxlibdir} -lbfd -ldl -liberty -lz"
  15931. # if --with-BFD=DIR has been specified, use it.
  15932. if test "x${BFD_DIR}" != "x"; then
  15933. BFD_INCLUDE="-I${BFD_DIR}/include"
  15934. fi
  15935. BFD_INCLUDE="${BFD_INCLUDE} "
  15936. if test "xbfd.h" = "x" ; then # no header, assume found
  15937. BFD_HEADER_FOUND="1"
  15938. else # check for the header
  15939. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  15940. CPPFLAGS="${CPPFLAGS} ${BFD_INCLUDE}"
  15941. ac_fn_c_check_header_mongrel "$LINENO" "bfd.h" "ac_cv_header_bfd_h" "$ac_includes_default"
  15942. if test "x$ac_cv_header_bfd_h" = xyes; then :
  15943. BFD_HEADER_FOUND=1
  15944. else
  15945. BFD_HEADER_FOUND=0
  15946. fi
  15947. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  15948. fi
  15949. if test "x${BFD_HEADER_FOUND}" = "x0" ; then
  15950. BFD_LIB=""
  15951. BFD_INCLUDE=""
  15952. else
  15953. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  15954. BFD_LIB=""
  15955. fi
  15956. PBX_BFD=1
  15957. cat >>confdefs.h <<_ACEOF
  15958. #define HAVE_BFD 1
  15959. _ACEOF
  15960. fi
  15961. fi
  15962. fi
  15963. fi
  15964. if test "x${OSARCH}" = "xlinux-gnu" ; then
  15965. if test "x${PBX_CAP}" != "x1" -a "${USE_CAP}" != "no"; then
  15966. pbxlibdir=""
  15967. # if --with-CAP=DIR has been specified, use it.
  15968. if test "x${CAP_DIR}" != "x"; then
  15969. if test -d ${CAP_DIR}/lib; then
  15970. pbxlibdir="-L${CAP_DIR}/lib"
  15971. else
  15972. pbxlibdir="-L${CAP_DIR}"
  15973. fi
  15974. fi
  15975. pbxfuncname="cap_from_text"
  15976. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  15977. AST_CAP_FOUND=yes
  15978. else
  15979. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  15980. CFLAGS="${CFLAGS} "
  15981. as_ac_Lib=`$as_echo "ac_cv_lib_cap_${pbxfuncname}" | $as_tr_sh`
  15982. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcap" >&5
  15983. $as_echo_n "checking for ${pbxfuncname} in -lcap... " >&6; }
  15984. if eval \${$as_ac_Lib+:} false; then :
  15985. $as_echo_n "(cached) " >&6
  15986. else
  15987. ac_check_lib_save_LIBS=$LIBS
  15988. LIBS="-lcap ${pbxlibdir} $LIBS"
  15989. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  15990. /* end confdefs.h. */
  15991. /* Override any GCC internal prototype to avoid an error.
  15992. Use char because int might match the return type of a GCC
  15993. builtin and then its argument prototype would still apply. */
  15994. #ifdef __cplusplus
  15995. extern "C"
  15996. #endif
  15997. char ${pbxfuncname} ();
  15998. int
  15999. main ()
  16000. {
  16001. return ${pbxfuncname} ();
  16002. ;
  16003. return 0;
  16004. }
  16005. _ACEOF
  16006. if ac_fn_c_try_link "$LINENO"; then :
  16007. eval "$as_ac_Lib=yes"
  16008. else
  16009. eval "$as_ac_Lib=no"
  16010. fi
  16011. rm -f core conftest.err conftest.$ac_objext \
  16012. conftest$ac_exeext conftest.$ac_ext
  16013. LIBS=$ac_check_lib_save_LIBS
  16014. fi
  16015. eval ac_res=\$$as_ac_Lib
  16016. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16017. $as_echo "$ac_res" >&6; }
  16018. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16019. AST_CAP_FOUND=yes
  16020. else
  16021. AST_CAP_FOUND=no
  16022. fi
  16023. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16024. fi
  16025. # now check for the header.
  16026. if test "${AST_CAP_FOUND}" = "yes"; then
  16027. CAP_LIB="${pbxlibdir} -lcap "
  16028. # if --with-CAP=DIR has been specified, use it.
  16029. if test "x${CAP_DIR}" != "x"; then
  16030. CAP_INCLUDE="-I${CAP_DIR}/include"
  16031. fi
  16032. CAP_INCLUDE="${CAP_INCLUDE} "
  16033. if test "xsys/capability.h" = "x" ; then # no header, assume found
  16034. CAP_HEADER_FOUND="1"
  16035. else # check for the header
  16036. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16037. CPPFLAGS="${CPPFLAGS} ${CAP_INCLUDE}"
  16038. ac_fn_c_check_header_mongrel "$LINENO" "sys/capability.h" "ac_cv_header_sys_capability_h" "$ac_includes_default"
  16039. if test "x$ac_cv_header_sys_capability_h" = xyes; then :
  16040. CAP_HEADER_FOUND=1
  16041. else
  16042. CAP_HEADER_FOUND=0
  16043. fi
  16044. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16045. fi
  16046. if test "x${CAP_HEADER_FOUND}" = "x0" ; then
  16047. CAP_LIB=""
  16048. CAP_INCLUDE=""
  16049. else
  16050. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16051. CAP_LIB=""
  16052. fi
  16053. PBX_CAP=1
  16054. cat >>confdefs.h <<_ACEOF
  16055. #define HAVE_CAP 1
  16056. _ACEOF
  16057. fi
  16058. fi
  16059. fi
  16060. fi
  16061. if test "x${PBX_DAHDI}" != "x1"; then
  16062. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_RESET_COUNTERS in dahdi/user.h" >&5
  16063. $as_echo_n "checking for DAHDI_RESET_COUNTERS in dahdi/user.h... " >&6; }
  16064. saved_cppflags="${CPPFLAGS}"
  16065. if test "x${DAHDI_DIR}" != "x"; then
  16066. DAHDI_INCLUDE="-I${DAHDI_DIR}/include"
  16067. fi
  16068. CPPFLAGS="${CPPFLAGS} ${DAHDI_INCLUDE}"
  16069. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16070. /* end confdefs.h. */
  16071. #include <dahdi/user.h>
  16072. int
  16073. main ()
  16074. {
  16075. #if defined(DAHDI_RESET_COUNTERS)
  16076. int foo = 0;
  16077. #else
  16078. int foo = bar;
  16079. #endif
  16080. 0
  16081. ;
  16082. return 0;
  16083. }
  16084. _ACEOF
  16085. if ac_fn_c_try_compile "$LINENO"; then :
  16086. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16087. $as_echo "yes" >&6; }
  16088. PBX_DAHDI=1
  16089. $as_echo "#define HAVE_DAHDI 1" >>confdefs.h
  16090. $as_echo "#define HAVE_DAHDI_VERSION 230" >>confdefs.h
  16091. else
  16092. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16093. $as_echo "no" >&6; }
  16094. fi
  16095. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16096. CPPFLAGS="${saved_cppflags}"
  16097. fi
  16098. if test "x${PBX_DAHDI}" != "x1"; then
  16099. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_DEFAULT_MTU_MRU in dahdi/user.h" >&5
  16100. $as_echo_n "checking for DAHDI_DEFAULT_MTU_MRU in dahdi/user.h... " >&6; }
  16101. saved_cppflags="${CPPFLAGS}"
  16102. if test "x${DAHDI_DIR}" != "x"; then
  16103. DAHDI_INCLUDE="-I${DAHDI_DIR}/include"
  16104. fi
  16105. CPPFLAGS="${CPPFLAGS} ${DAHDI_INCLUDE}"
  16106. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16107. /* end confdefs.h. */
  16108. #include <dahdi/user.h>
  16109. int
  16110. main ()
  16111. {
  16112. #if defined(DAHDI_DEFAULT_MTU_MRU)
  16113. int foo = 0;
  16114. #else
  16115. int foo = bar;
  16116. #endif
  16117. 0
  16118. ;
  16119. return 0;
  16120. }
  16121. _ACEOF
  16122. if ac_fn_c_try_compile "$LINENO"; then :
  16123. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16124. $as_echo "yes" >&6; }
  16125. PBX_DAHDI=1
  16126. $as_echo "#define HAVE_DAHDI 1" >>confdefs.h
  16127. $as_echo "#define HAVE_DAHDI_VERSION 220" >>confdefs.h
  16128. else
  16129. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16130. $as_echo "no" >&6; }
  16131. fi
  16132. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16133. CPPFLAGS="${saved_cppflags}"
  16134. fi
  16135. if test "x${PBX_DAHDI}" != "x1"; then
  16136. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_CODE in dahdi/user.h" >&5
  16137. $as_echo_n "checking for DAHDI_CODE in dahdi/user.h... " >&6; }
  16138. saved_cppflags="${CPPFLAGS}"
  16139. if test "x${DAHDI_DIR}" != "x"; then
  16140. DAHDI_INCLUDE="-I${DAHDI_DIR}/include"
  16141. fi
  16142. CPPFLAGS="${CPPFLAGS} ${DAHDI_INCLUDE}"
  16143. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16144. /* end confdefs.h. */
  16145. #include <dahdi/user.h>
  16146. int
  16147. main ()
  16148. {
  16149. #if defined(DAHDI_CODE)
  16150. int foo = 0;
  16151. #else
  16152. int foo = bar;
  16153. #endif
  16154. 0
  16155. ;
  16156. return 0;
  16157. }
  16158. _ACEOF
  16159. if ac_fn_c_try_compile "$LINENO"; then :
  16160. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16161. $as_echo "yes" >&6; }
  16162. PBX_DAHDI=1
  16163. $as_echo "#define HAVE_DAHDI 1" >>confdefs.h
  16164. $as_echo "#define HAVE_DAHDI_VERSION 200" >>confdefs.h
  16165. else
  16166. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16167. $as_echo "no" >&6; }
  16168. fi
  16169. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16170. CPPFLAGS="${saved_cppflags}"
  16171. fi
  16172. if test "x${PBX_DAHDI_HALF_FULL}" != "x1"; then
  16173. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DAHDI_POLICY_HALF_FULL in dahdi/user.h" >&5
  16174. $as_echo_n "checking for DAHDI_POLICY_HALF_FULL in dahdi/user.h... " >&6; }
  16175. saved_cppflags="${CPPFLAGS}"
  16176. if test "x${DAHDI_HALF_FULL_DIR}" != "x"; then
  16177. DAHDI_HALF_FULL_INCLUDE="-I${DAHDI_HALF_FULL_DIR}/include"
  16178. fi
  16179. CPPFLAGS="${CPPFLAGS} ${DAHDI_HALF_FULL_INCLUDE}"
  16180. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16181. /* end confdefs.h. */
  16182. #include <dahdi/user.h>
  16183. int
  16184. main ()
  16185. {
  16186. #if defined(DAHDI_POLICY_HALF_FULL)
  16187. int foo = 0;
  16188. #else
  16189. int foo = bar;
  16190. #endif
  16191. 0
  16192. ;
  16193. return 0;
  16194. }
  16195. _ACEOF
  16196. if ac_fn_c_try_compile "$LINENO"; then :
  16197. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16198. $as_echo "yes" >&6; }
  16199. PBX_DAHDI_HALF_FULL=1
  16200. $as_echo "#define HAVE_DAHDI_HALF_FULL 1" >>confdefs.h
  16201. else
  16202. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16203. $as_echo "no" >&6; }
  16204. fi
  16205. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16206. CPPFLAGS="${saved_cppflags}"
  16207. fi
  16208. if test "x${PBX_DAHDI_LINEREVERSE_VMWI}" != "x1" -a "${USE_DAHDI_LINEREVERSE_VMWI}" != "no"; then
  16209. if test "xenhanced dahdi vmwi support" != "x"; then
  16210. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for enhanced dahdi vmwi support" >&5
  16211. $as_echo_n "checking for enhanced dahdi vmwi support... " >&6; }
  16212. else
  16213. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"struct dahdi_vmwi_info booger\" compiles using dahdi/user.h" >&5
  16214. $as_echo_n "checking if \"struct dahdi_vmwi_info booger\" compiles using dahdi/user.h... " >&6; }
  16215. fi
  16216. saved_cppflags="${CPPFLAGS}"
  16217. if test "x${DAHDI_LINEREVERSE_VMWI_DIR}" != "x"; then
  16218. DAHDI_LINEREVERSE_VMWI_INCLUDE="-I${DAHDI_LINEREVERSE_VMWI_DIR}/include"
  16219. fi
  16220. CPPFLAGS="${CPPFLAGS} ${DAHDI_LINEREVERSE_VMWI_INCLUDE}"
  16221. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16222. /* end confdefs.h. */
  16223. #include <dahdi/user.h>
  16224. int
  16225. main ()
  16226. {
  16227. struct dahdi_vmwi_info booger;
  16228. ;
  16229. return 0;
  16230. }
  16231. _ACEOF
  16232. if ac_fn_c_try_compile "$LINENO"; then :
  16233. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16234. $as_echo "yes" >&6; }
  16235. PBX_DAHDI_LINEREVERSE_VMWI=1
  16236. $as_echo "#define HAVE_DAHDI_LINEREVERSE_VMWI 1" >>confdefs.h
  16237. else
  16238. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16239. $as_echo "no" >&6; }
  16240. fi
  16241. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16242. CPPFLAGS="${saved_cppflags}"
  16243. fi
  16244. if test "x${PBX_DAHDI_ECHOCANCEL_FAX_MODE}" != "x1" -a "${USE_DAHDI_ECHOCANCEL_FAX_MODE}" != "no"; then
  16245. if test "x" != "x"; then
  16246. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for " >&5
  16247. $as_echo_n "checking for ... " >&6; }
  16248. else
  16249. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"int foo = DAHDI_ECHOCANCEL_FAX_MODE\" compiles using dahdi/user.h" >&5
  16250. $as_echo_n "checking if \"int foo = DAHDI_ECHOCANCEL_FAX_MODE\" compiles using dahdi/user.h... " >&6; }
  16251. fi
  16252. saved_cppflags="${CPPFLAGS}"
  16253. if test "x${DAHDI_ECHOCANCEL_FAX_MODE_DIR}" != "x"; then
  16254. DAHDI_ECHOCANCEL_FAX_MODE_INCLUDE="-I${DAHDI_ECHOCANCEL_FAX_MODE_DIR}/include"
  16255. fi
  16256. CPPFLAGS="${CPPFLAGS} ${DAHDI_ECHOCANCEL_FAX_MODE_INCLUDE}"
  16257. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16258. /* end confdefs.h. */
  16259. #include <dahdi/user.h>
  16260. int
  16261. main ()
  16262. {
  16263. int foo = DAHDI_ECHOCANCEL_FAX_MODE;
  16264. ;
  16265. return 0;
  16266. }
  16267. _ACEOF
  16268. if ac_fn_c_try_compile "$LINENO"; then :
  16269. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16270. $as_echo "yes" >&6; }
  16271. PBX_DAHDI_ECHOCANCEL_FAX_MODE=1
  16272. $as_echo "#define HAVE_DAHDI_ECHOCANCEL_FAX_MODE 1" >>confdefs.h
  16273. else
  16274. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16275. $as_echo "no" >&6; }
  16276. fi
  16277. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16278. CPPFLAGS="${saved_cppflags}"
  16279. fi
  16280. if test "x${PBX_GETIFADDRS}" != "x1" -a "${USE_GETIFADDRS}" != "no"; then
  16281. if test "xgetifaddrs() support" != "x"; then
  16282. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getifaddrs() support" >&5
  16283. $as_echo_n "checking for getifaddrs() support... " >&6; }
  16284. else
  16285. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"struct ifaddrs *p; getifaddrs(&p)\" compiles using ifaddrs.h" >&5
  16286. $as_echo_n "checking if \"struct ifaddrs *p; getifaddrs(&p)\" compiles using ifaddrs.h... " >&6; }
  16287. fi
  16288. saved_cppflags="${CPPFLAGS}"
  16289. if test "x${GETIFADDRS_DIR}" != "x"; then
  16290. GETIFADDRS_INCLUDE="-I${GETIFADDRS_DIR}/include"
  16291. fi
  16292. CPPFLAGS="${CPPFLAGS} ${GETIFADDRS_INCLUDE}"
  16293. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16294. /* end confdefs.h. */
  16295. #include <ifaddrs.h>
  16296. int
  16297. main ()
  16298. {
  16299. struct ifaddrs *p; getifaddrs(&p);
  16300. ;
  16301. return 0;
  16302. }
  16303. _ACEOF
  16304. if ac_fn_c_try_compile "$LINENO"; then :
  16305. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16306. $as_echo "yes" >&6; }
  16307. PBX_GETIFADDRS=1
  16308. $as_echo "#define HAVE_GETIFADDRS 1" >>confdefs.h
  16309. else
  16310. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16311. $as_echo "no" >&6; }
  16312. fi
  16313. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16314. CPPFLAGS="${saved_cppflags}"
  16315. fi
  16316. if test "x${PBX_TIMERFD}" != "x1" -a "${USE_TIMERFD}" != "no"; then
  16317. if test "xtimerfd support" != "x"; then
  16318. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for timerfd support" >&5
  16319. $as_echo_n "checking for timerfd support... " >&6; }
  16320. else
  16321. { $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
  16322. $as_echo_n "checking if \"timerfd_create(0,0); timerfd_settime(0,0,NULL,NULL);\" compiles using sys/timerfd.h... " >&6; }
  16323. fi
  16324. saved_cppflags="${CPPFLAGS}"
  16325. if test "x${TIMERFD_DIR}" != "x"; then
  16326. TIMERFD_INCLUDE="-I${TIMERFD_DIR}/include"
  16327. fi
  16328. CPPFLAGS="${CPPFLAGS} ${TIMERFD_INCLUDE}"
  16329. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16330. /* end confdefs.h. */
  16331. #include <sys/timerfd.h>
  16332. int
  16333. main ()
  16334. {
  16335. timerfd_create(0,0); timerfd_settime(0,0,NULL,NULL);;
  16336. ;
  16337. return 0;
  16338. }
  16339. _ACEOF
  16340. if ac_fn_c_try_compile "$LINENO"; then :
  16341. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16342. $as_echo "yes" >&6; }
  16343. PBX_TIMERFD=1
  16344. $as_echo "#define HAVE_TIMERFD 1" >>confdefs.h
  16345. else
  16346. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16347. $as_echo "no" >&6; }
  16348. fi
  16349. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  16350. CPPFLAGS="${saved_cppflags}"
  16351. fi
  16352. GSM_INTERNAL="yes"
  16353. GSM_SYSTEM="yes"
  16354. if test "${USE_GSM}" != "no"; then
  16355. if test "${GSM_DIR}" = "internal"; then
  16356. GSM_SYSTEM="no"
  16357. elif test "${GSM_DIR}" != ""; then
  16358. GSM_INTERNAL="no"
  16359. fi
  16360. if test "${GSM_SYSTEM}" = "yes"; then
  16361. gsmlibdir=""
  16362. if test "x${GSM_DIR}" != "x"; then
  16363. if test -d ${GSM_DIR}/lib; then
  16364. gsmlibdir="-L${GSM_DIR}/lib"
  16365. else
  16366. gsmlibdir="-L${GSM_DIR}"
  16367. fi
  16368. fi
  16369. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gsm_create in -lgsm" >&5
  16370. $as_echo_n "checking for gsm_create in -lgsm... " >&6; }
  16371. if ${ac_cv_lib_gsm_gsm_create+:} false; then :
  16372. $as_echo_n "(cached) " >&6
  16373. else
  16374. ac_check_lib_save_LIBS=$LIBS
  16375. LIBS="-lgsm ${gsmlibdir} $LIBS"
  16376. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16377. /* end confdefs.h. */
  16378. /* Override any GCC internal prototype to avoid an error.
  16379. Use char because int might match the return type of a GCC
  16380. builtin and then its argument prototype would still apply. */
  16381. #ifdef __cplusplus
  16382. extern "C"
  16383. #endif
  16384. char gsm_create ();
  16385. int
  16386. main ()
  16387. {
  16388. return gsm_create ();
  16389. ;
  16390. return 0;
  16391. }
  16392. _ACEOF
  16393. if ac_fn_c_try_link "$LINENO"; then :
  16394. ac_cv_lib_gsm_gsm_create=yes
  16395. else
  16396. ac_cv_lib_gsm_gsm_create=no
  16397. fi
  16398. rm -f core conftest.err conftest.$ac_objext \
  16399. conftest$ac_exeext conftest.$ac_ext
  16400. LIBS=$ac_check_lib_save_LIBS
  16401. fi
  16402. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gsm_gsm_create" >&5
  16403. $as_echo "$ac_cv_lib_gsm_gsm_create" >&6; }
  16404. if test "x$ac_cv_lib_gsm_gsm_create" = xyes; then :
  16405. cat >>confdefs.h <<_ACEOF
  16406. #define HAVE_GSM 1
  16407. _ACEOF
  16408. fi
  16409. if test "${ac_cv_lib_gsm_gsm_create}" = "yes"; then
  16410. if test "x${GSM_DIR}" != "x" ; then
  16411. as_ac_Header=`$as_echo "ac_cv_header_${GSM_DIR}/include/gsm.h" | $as_tr_sh`
  16412. ac_fn_c_check_header_mongrel "$LINENO" "${GSM_DIR}/include/gsm.h" "$as_ac_Header" "$ac_includes_default"
  16413. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  16414. GSM_HEADER_FOUND=1
  16415. else
  16416. GSM_HEADER_FOUND=0
  16417. fi
  16418. as_ac_Header=`$as_echo "ac_cv_header_${GSM_DIR}/include/gsm/gsm.h" | $as_tr_sh`
  16419. ac_fn_c_check_header_mongrel "$LINENO" "${GSM_DIR}/include/gsm/gsm.h" "$as_ac_Header" "$ac_includes_default"
  16420. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  16421. GSM_GSM_HEADER_FOUND=1
  16422. else
  16423. GSM_GSM_HEADER_FOUND=0
  16424. fi
  16425. else
  16426. ac_fn_c_check_header_mongrel "$LINENO" "gsm.h" "ac_cv_header_gsm_h" "$ac_includes_default"
  16427. if test "x$ac_cv_header_gsm_h" = xyes; then :
  16428. GSM_HEADER_FOUND=1
  16429. else
  16430. GSM_HEADER_FOUND=0
  16431. fi
  16432. ac_fn_c_check_header_mongrel "$LINENO" "gsm/gsm.h" "ac_cv_header_gsm_gsm_h" "$ac_includes_default"
  16433. if test "x$ac_cv_header_gsm_gsm_h" = xyes; then :
  16434. GSM_GSM_HEADER_FOUND=1
  16435. else
  16436. GSM_GSM_HEADER_FOUND=0
  16437. fi
  16438. fi
  16439. if test "${GSM_HEADER_FOUND}" = "0" ; then
  16440. if test "{GSM_GSM_HEADER_FOUND}" = "0" ; then
  16441. if test "x${GSM_MANDATORY}" = "xyes" ; then
  16442. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  16443. $as_echo "$as_me: ***" >&6;}
  16444. { $as_echo "$as_me:${as_lineno-$LINENO}: *** It appears that you do not have the gsm development package installed." >&5
  16445. $as_echo "$as_me: *** It appears that you do not have the gsm development package installed." >&6;}
  16446. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Please install it to include ${GSM_DESCRIP} support, or re-run configure" >&5
  16447. $as_echo "$as_me: *** Please install it to include ${GSM_DESCRIP} support, or re-run configure" >&6;}
  16448. { $as_echo "$as_me:${as_lineno-$LINENO}: *** without explicitly specifying --with-${GSM_OPTION}" >&5
  16449. $as_echo "$as_me: *** without explicitly specifying --with-${GSM_OPTION}" >&6;}
  16450. exit 1
  16451. fi
  16452. fi
  16453. fi
  16454. GSM_OK=0
  16455. if test "${GSM_HEADER_FOUND}" = "1" ; then
  16456. cat >>confdefs.h <<_ACEOF
  16457. #define HAVE_GSM_HEADER 1
  16458. _ACEOF
  16459. GSM_OK=1
  16460. else
  16461. if test "${GSM_GSM_HEADER_FOUND}" = "1" ; then
  16462. cat >>confdefs.h <<_ACEOF
  16463. #define HAVE_GSM_GSM_HEADER 1
  16464. _ACEOF
  16465. GSM_OK=1
  16466. fi
  16467. fi
  16468. if test "${GSM_OK}" = "1" ; then
  16469. GSM_LIB="-lgsm"
  16470. if test "x${GSM_DIR}" != "x"; then
  16471. GSM_LIB="${gsmlibdir} ${GSM_LIB}"
  16472. GSM_INCLUDE="-I${GSM_DIR}/include"
  16473. fi
  16474. PBX_GSM=1
  16475. GSM_INTERNAL="no"
  16476. fi
  16477. fi
  16478. fi
  16479. if test "${GSM_INTERNAL}" = "yes"; then
  16480. PBX_GSM=1
  16481. cat >>confdefs.h <<_ACEOF
  16482. #define HAVE_GSM_HEADER 1
  16483. _ACEOF
  16484. fi
  16485. fi
  16486. ILBC_INTERNAL="yes"
  16487. ILBC_SYSTEM="yes"
  16488. if test "${USE_ILBC}" != "no"; then
  16489. if test "${ILBC_DIR}" = "internal"; then
  16490. ILBC_SYSTEM="no"
  16491. elif test "${ILBC_DIR}" != ""; then
  16492. ILBC_INTERNAL="no"
  16493. fi
  16494. if test "${ILBC_SYSTEM}" = "yes"; then
  16495. if test "x${PBX_ILBC}" != "x1" -a "${USE_ILBC}" != "no"; then
  16496. pkg_failed=no
  16497. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ILBC" >&5
  16498. $as_echo_n "checking for ILBC... " >&6; }
  16499. if test -n "$ILBC_CFLAGS"; then
  16500. pkg_cv_ILBC_CFLAGS="$ILBC_CFLAGS"
  16501. elif test -n "$PKG_CONFIG"; then
  16502. if test -n "$PKG_CONFIG" && \
  16503. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libilbc\""; } >&5
  16504. ($PKG_CONFIG --exists --print-errors "libilbc") 2>&5
  16505. ac_status=$?
  16506. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16507. test $ac_status = 0; }; then
  16508. pkg_cv_ILBC_CFLAGS=`$PKG_CONFIG --cflags "libilbc" 2>/dev/null`
  16509. test "x$?" != "x0" && pkg_failed=yes
  16510. else
  16511. pkg_failed=yes
  16512. fi
  16513. else
  16514. pkg_failed=untried
  16515. fi
  16516. if test -n "$ILBC_LIBS"; then
  16517. pkg_cv_ILBC_LIBS="$ILBC_LIBS"
  16518. elif test -n "$PKG_CONFIG"; then
  16519. if test -n "$PKG_CONFIG" && \
  16520. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libilbc\""; } >&5
  16521. ($PKG_CONFIG --exists --print-errors "libilbc") 2>&5
  16522. ac_status=$?
  16523. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16524. test $ac_status = 0; }; then
  16525. pkg_cv_ILBC_LIBS=`$PKG_CONFIG --libs "libilbc" 2>/dev/null`
  16526. test "x$?" != "x0" && pkg_failed=yes
  16527. else
  16528. pkg_failed=yes
  16529. fi
  16530. else
  16531. pkg_failed=untried
  16532. fi
  16533. if test $pkg_failed = yes; then
  16534. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16535. $as_echo "no" >&6; }
  16536. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  16537. _pkg_short_errors_supported=yes
  16538. else
  16539. _pkg_short_errors_supported=no
  16540. fi
  16541. if test $_pkg_short_errors_supported = yes; then
  16542. ILBC_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libilbc" 2>&1`
  16543. else
  16544. ILBC_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libilbc" 2>&1`
  16545. fi
  16546. # Put the nasty error message in config.log where it belongs
  16547. echo "$ILBC_PKG_ERRORS" >&5
  16548. PBX_ILBC=0
  16549. elif test $pkg_failed = untried; then
  16550. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16551. $as_echo "no" >&6; }
  16552. PBX_ILBC=0
  16553. else
  16554. ILBC_CFLAGS=$pkg_cv_ILBC_CFLAGS
  16555. ILBC_LIBS=$pkg_cv_ILBC_LIBS
  16556. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16557. $as_echo "yes" >&6; }
  16558. PBX_ILBC=1
  16559. ILBC_INCLUDE="$ILBC_CFLAGS"
  16560. ILBC_LIB="$ILBC_LIBS"
  16561. $as_echo "#define HAVE_ILBC 1" >>confdefs.h
  16562. fi
  16563. fi
  16564. if test "$PBX_ILBC" = "1"; then
  16565. ILBC_INTERNAL="no"
  16566. fi
  16567. fi
  16568. if test "${ILBC_INTERNAL}" = "yes"; then
  16569. PBX_ILBC=1
  16570. fi
  16571. fi
  16572. LIBEDIT_INTERNAL="yes"
  16573. LIBEDIT_SYSTEM="yes"
  16574. if test "${USE_LIBEDIT}" != "no"; then
  16575. if test "${LIBEDIT_DIR}" = "internal"; then
  16576. LIBEDIT_SYSTEM="no"
  16577. elif test "${LIBEDIT_DIR}" != ""; then
  16578. LIBEDIT_INTERNAL="no"
  16579. fi
  16580. if test "${LIBEDIT_SYSTEM}" = "yes"; then
  16581. if test "x${PBX_LIBEDIT}" != "x1" -a "${USE_LIBEDIT}" != "no"; then
  16582. pkg_failed=no
  16583. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBEDIT" >&5
  16584. $as_echo_n "checking for LIBEDIT... " >&6; }
  16585. if test -n "$LIBEDIT_CFLAGS"; then
  16586. pkg_cv_LIBEDIT_CFLAGS="$LIBEDIT_CFLAGS"
  16587. elif test -n "$PKG_CONFIG"; then
  16588. if test -n "$PKG_CONFIG" && \
  16589. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libedit\""; } >&5
  16590. ($PKG_CONFIG --exists --print-errors "libedit") 2>&5
  16591. ac_status=$?
  16592. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16593. test $ac_status = 0; }; then
  16594. pkg_cv_LIBEDIT_CFLAGS=`$PKG_CONFIG --cflags "libedit" 2>/dev/null`
  16595. test "x$?" != "x0" && pkg_failed=yes
  16596. else
  16597. pkg_failed=yes
  16598. fi
  16599. else
  16600. pkg_failed=untried
  16601. fi
  16602. if test -n "$LIBEDIT_LIBS"; then
  16603. pkg_cv_LIBEDIT_LIBS="$LIBEDIT_LIBS"
  16604. elif test -n "$PKG_CONFIG"; then
  16605. if test -n "$PKG_CONFIG" && \
  16606. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libedit\""; } >&5
  16607. ($PKG_CONFIG --exists --print-errors "libedit") 2>&5
  16608. ac_status=$?
  16609. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  16610. test $ac_status = 0; }; then
  16611. pkg_cv_LIBEDIT_LIBS=`$PKG_CONFIG --libs "libedit" 2>/dev/null`
  16612. test "x$?" != "x0" && pkg_failed=yes
  16613. else
  16614. pkg_failed=yes
  16615. fi
  16616. else
  16617. pkg_failed=untried
  16618. fi
  16619. if test $pkg_failed = yes; then
  16620. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16621. $as_echo "no" >&6; }
  16622. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  16623. _pkg_short_errors_supported=yes
  16624. else
  16625. _pkg_short_errors_supported=no
  16626. fi
  16627. if test $_pkg_short_errors_supported = yes; then
  16628. LIBEDIT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libedit" 2>&1`
  16629. else
  16630. LIBEDIT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libedit" 2>&1`
  16631. fi
  16632. # Put the nasty error message in config.log where it belongs
  16633. echo "$LIBEDIT_PKG_ERRORS" >&5
  16634. PBX_LIBEDIT=0
  16635. elif test $pkg_failed = untried; then
  16636. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  16637. $as_echo "no" >&6; }
  16638. PBX_LIBEDIT=0
  16639. else
  16640. LIBEDIT_CFLAGS=$pkg_cv_LIBEDIT_CFLAGS
  16641. LIBEDIT_LIBS=$pkg_cv_LIBEDIT_LIBS
  16642. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  16643. $as_echo "yes" >&6; }
  16644. PBX_LIBEDIT=1
  16645. LIBEDIT_INCLUDE="$LIBEDIT_CFLAGS"
  16646. LIBEDIT_LIB="$LIBEDIT_LIBS"
  16647. $as_echo "#define HAVE_LIBEDIT 1" >>confdefs.h
  16648. fi
  16649. fi
  16650. if test "$PBX_LIBEDIT" = "1"; then
  16651. LIBEDIT_INTERNAL="no"
  16652. fi
  16653. fi
  16654. if test "${LIBEDIT_INTERNAL}" = "yes"; then
  16655. PBX_LIBEDIT=1
  16656. fi
  16657. fi
  16658. if test "x${PBX_ICONV}" != "x1" -a "${USE_ICONV}" != "no"; then
  16659. pbxlibdir=""
  16660. # if --with-ICONV=DIR has been specified, use it.
  16661. if test "x${ICONV_DIR}" != "x"; then
  16662. if test -d ${ICONV_DIR}/lib; then
  16663. pbxlibdir="-L${ICONV_DIR}/lib"
  16664. else
  16665. pbxlibdir="-L${ICONV_DIR}"
  16666. fi
  16667. fi
  16668. pbxfuncname="iconv_open"
  16669. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16670. AST_ICONV_FOUND=yes
  16671. else
  16672. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16673. CFLAGS="${CFLAGS} "
  16674. as_ac_Lib=`$as_echo "ac_cv_lib_iconv_${pbxfuncname}" | $as_tr_sh`
  16675. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liconv" >&5
  16676. $as_echo_n "checking for ${pbxfuncname} in -liconv... " >&6; }
  16677. if eval \${$as_ac_Lib+:} false; then :
  16678. $as_echo_n "(cached) " >&6
  16679. else
  16680. ac_check_lib_save_LIBS=$LIBS
  16681. LIBS="-liconv ${pbxlibdir} $LIBS"
  16682. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16683. /* end confdefs.h. */
  16684. /* Override any GCC internal prototype to avoid an error.
  16685. Use char because int might match the return type of a GCC
  16686. builtin and then its argument prototype would still apply. */
  16687. #ifdef __cplusplus
  16688. extern "C"
  16689. #endif
  16690. char ${pbxfuncname} ();
  16691. int
  16692. main ()
  16693. {
  16694. return ${pbxfuncname} ();
  16695. ;
  16696. return 0;
  16697. }
  16698. _ACEOF
  16699. if ac_fn_c_try_link "$LINENO"; then :
  16700. eval "$as_ac_Lib=yes"
  16701. else
  16702. eval "$as_ac_Lib=no"
  16703. fi
  16704. rm -f core conftest.err conftest.$ac_objext \
  16705. conftest$ac_exeext conftest.$ac_ext
  16706. LIBS=$ac_check_lib_save_LIBS
  16707. fi
  16708. eval ac_res=\$$as_ac_Lib
  16709. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16710. $as_echo "$ac_res" >&6; }
  16711. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16712. AST_ICONV_FOUND=yes
  16713. else
  16714. AST_ICONV_FOUND=no
  16715. fi
  16716. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16717. fi
  16718. # now check for the header.
  16719. if test "${AST_ICONV_FOUND}" = "yes"; then
  16720. ICONV_LIB="${pbxlibdir} -liconv "
  16721. # if --with-ICONV=DIR has been specified, use it.
  16722. if test "x${ICONV_DIR}" != "x"; then
  16723. ICONV_INCLUDE="-I${ICONV_DIR}/include"
  16724. fi
  16725. ICONV_INCLUDE="${ICONV_INCLUDE} "
  16726. if test "xiconv.h" = "x" ; then # no header, assume found
  16727. ICONV_HEADER_FOUND="1"
  16728. else # check for the header
  16729. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16730. CPPFLAGS="${CPPFLAGS} ${ICONV_INCLUDE}"
  16731. ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
  16732. if test "x$ac_cv_header_iconv_h" = xyes; then :
  16733. ICONV_HEADER_FOUND=1
  16734. else
  16735. ICONV_HEADER_FOUND=0
  16736. fi
  16737. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16738. fi
  16739. if test "x${ICONV_HEADER_FOUND}" = "x0" ; then
  16740. ICONV_LIB=""
  16741. ICONV_INCLUDE=""
  16742. else
  16743. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16744. ICONV_LIB=""
  16745. fi
  16746. PBX_ICONV=1
  16747. cat >>confdefs.h <<_ACEOF
  16748. #define HAVE_ICONV 1
  16749. _ACEOF
  16750. fi
  16751. fi
  16752. fi
  16753. # GNU libiconv #define's iconv_open to libiconv_open, so we need to search for that symbol
  16754. if test "x${PBX_ICONV}" != "x1" -a "${USE_ICONV}" != "no"; then
  16755. pbxlibdir=""
  16756. # if --with-ICONV=DIR has been specified, use it.
  16757. if test "x${ICONV_DIR}" != "x"; then
  16758. if test -d ${ICONV_DIR}/lib; then
  16759. pbxlibdir="-L${ICONV_DIR}/lib"
  16760. else
  16761. pbxlibdir="-L${ICONV_DIR}"
  16762. fi
  16763. fi
  16764. pbxfuncname="libiconv_open"
  16765. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16766. AST_ICONV_FOUND=yes
  16767. else
  16768. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16769. CFLAGS="${CFLAGS} "
  16770. as_ac_Lib=`$as_echo "ac_cv_lib_iconv_${pbxfuncname}" | $as_tr_sh`
  16771. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liconv" >&5
  16772. $as_echo_n "checking for ${pbxfuncname} in -liconv... " >&6; }
  16773. if eval \${$as_ac_Lib+:} false; then :
  16774. $as_echo_n "(cached) " >&6
  16775. else
  16776. ac_check_lib_save_LIBS=$LIBS
  16777. LIBS="-liconv ${pbxlibdir} $LIBS"
  16778. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16779. /* end confdefs.h. */
  16780. /* Override any GCC internal prototype to avoid an error.
  16781. Use char because int might match the return type of a GCC
  16782. builtin and then its argument prototype would still apply. */
  16783. #ifdef __cplusplus
  16784. extern "C"
  16785. #endif
  16786. char ${pbxfuncname} ();
  16787. int
  16788. main ()
  16789. {
  16790. return ${pbxfuncname} ();
  16791. ;
  16792. return 0;
  16793. }
  16794. _ACEOF
  16795. if ac_fn_c_try_link "$LINENO"; then :
  16796. eval "$as_ac_Lib=yes"
  16797. else
  16798. eval "$as_ac_Lib=no"
  16799. fi
  16800. rm -f core conftest.err conftest.$ac_objext \
  16801. conftest$ac_exeext conftest.$ac_ext
  16802. LIBS=$ac_check_lib_save_LIBS
  16803. fi
  16804. eval ac_res=\$$as_ac_Lib
  16805. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16806. $as_echo "$ac_res" >&6; }
  16807. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16808. AST_ICONV_FOUND=yes
  16809. else
  16810. AST_ICONV_FOUND=no
  16811. fi
  16812. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16813. fi
  16814. # now check for the header.
  16815. if test "${AST_ICONV_FOUND}" = "yes"; then
  16816. ICONV_LIB="${pbxlibdir} -liconv "
  16817. # if --with-ICONV=DIR has been specified, use it.
  16818. if test "x${ICONV_DIR}" != "x"; then
  16819. ICONV_INCLUDE="-I${ICONV_DIR}/include"
  16820. fi
  16821. ICONV_INCLUDE="${ICONV_INCLUDE} "
  16822. if test "xiconv.h" = "x" ; then # no header, assume found
  16823. ICONV_HEADER_FOUND="1"
  16824. else # check for the header
  16825. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16826. CPPFLAGS="${CPPFLAGS} ${ICONV_INCLUDE}"
  16827. ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
  16828. if test "x$ac_cv_header_iconv_h" = xyes; then :
  16829. ICONV_HEADER_FOUND=1
  16830. else
  16831. ICONV_HEADER_FOUND=0
  16832. fi
  16833. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16834. fi
  16835. if test "x${ICONV_HEADER_FOUND}" = "x0" ; then
  16836. ICONV_LIB=""
  16837. ICONV_INCLUDE=""
  16838. else
  16839. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16840. ICONV_LIB=""
  16841. fi
  16842. PBX_ICONV=1
  16843. cat >>confdefs.h <<_ACEOF
  16844. #define HAVE_ICONV 1
  16845. _ACEOF
  16846. fi
  16847. fi
  16848. fi
  16849. # Some versions of Linux package iconv in glibc
  16850. if test "x${PBX_ICONV}" != "x1" -a "${USE_ICONV}" != "no"; then
  16851. pbxlibdir=""
  16852. # if --with-ICONV=DIR has been specified, use it.
  16853. if test "x${ICONV_DIR}" != "x"; then
  16854. if test -d ${ICONV_DIR}/lib; then
  16855. pbxlibdir="-L${ICONV_DIR}/lib"
  16856. else
  16857. pbxlibdir="-L${ICONV_DIR}"
  16858. fi
  16859. fi
  16860. pbxfuncname="iconv_close"
  16861. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16862. AST_ICONV_FOUND=yes
  16863. else
  16864. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16865. CFLAGS="${CFLAGS} "
  16866. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  16867. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  16868. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  16869. if eval \${$as_ac_Lib+:} false; then :
  16870. $as_echo_n "(cached) " >&6
  16871. else
  16872. ac_check_lib_save_LIBS=$LIBS
  16873. LIBS="-lc ${pbxlibdir} $LIBS"
  16874. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16875. /* end confdefs.h. */
  16876. /* Override any GCC internal prototype to avoid an error.
  16877. Use char because int might match the return type of a GCC
  16878. builtin and then its argument prototype would still apply. */
  16879. #ifdef __cplusplus
  16880. extern "C"
  16881. #endif
  16882. char ${pbxfuncname} ();
  16883. int
  16884. main ()
  16885. {
  16886. return ${pbxfuncname} ();
  16887. ;
  16888. return 0;
  16889. }
  16890. _ACEOF
  16891. if ac_fn_c_try_link "$LINENO"; then :
  16892. eval "$as_ac_Lib=yes"
  16893. else
  16894. eval "$as_ac_Lib=no"
  16895. fi
  16896. rm -f core conftest.err conftest.$ac_objext \
  16897. conftest$ac_exeext conftest.$ac_ext
  16898. LIBS=$ac_check_lib_save_LIBS
  16899. fi
  16900. eval ac_res=\$$as_ac_Lib
  16901. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16902. $as_echo "$ac_res" >&6; }
  16903. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  16904. AST_ICONV_FOUND=yes
  16905. else
  16906. AST_ICONV_FOUND=no
  16907. fi
  16908. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  16909. fi
  16910. # now check for the header.
  16911. if test "${AST_ICONV_FOUND}" = "yes"; then
  16912. ICONV_LIB="${pbxlibdir} -lc "
  16913. # if --with-ICONV=DIR has been specified, use it.
  16914. if test "x${ICONV_DIR}" != "x"; then
  16915. ICONV_INCLUDE="-I${ICONV_DIR}/include"
  16916. fi
  16917. ICONV_INCLUDE="${ICONV_INCLUDE} "
  16918. if test "xiconv.h" = "x" ; then # no header, assume found
  16919. ICONV_HEADER_FOUND="1"
  16920. else # check for the header
  16921. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  16922. CPPFLAGS="${CPPFLAGS} ${ICONV_INCLUDE}"
  16923. ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
  16924. if test "x$ac_cv_header_iconv_h" = xyes; then :
  16925. ICONV_HEADER_FOUND=1
  16926. else
  16927. ICONV_HEADER_FOUND=0
  16928. fi
  16929. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  16930. fi
  16931. if test "x${ICONV_HEADER_FOUND}" = "x0" ; then
  16932. ICONV_LIB=""
  16933. ICONV_INCLUDE=""
  16934. else
  16935. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  16936. ICONV_LIB=""
  16937. fi
  16938. PBX_ICONV=1
  16939. cat >>confdefs.h <<_ACEOF
  16940. #define HAVE_ICONV 1
  16941. _ACEOF
  16942. fi
  16943. fi
  16944. fi
  16945. # If ical.h is NOT in the libical directory, then it is of a version insufficient for us.
  16946. if test "x${PBX_ICAL}" != "x1" -a "${USE_ICAL}" != "no"; then
  16947. pbxlibdir=""
  16948. # if --with-ICAL=DIR has been specified, use it.
  16949. if test "x${ICAL_DIR}" != "x"; then
  16950. if test -d ${ICAL_DIR}/lib; then
  16951. pbxlibdir="-L${ICAL_DIR}/lib"
  16952. else
  16953. pbxlibdir="-L${ICAL_DIR}"
  16954. fi
  16955. fi
  16956. pbxfuncname="icaltimezone_get_utc_timezone"
  16957. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  16958. AST_ICAL_FOUND=yes
  16959. else
  16960. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  16961. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  16962. as_ac_Lib=`$as_echo "ac_cv_lib_ical_${pbxfuncname}" | $as_tr_sh`
  16963. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lical" >&5
  16964. $as_echo_n "checking for ${pbxfuncname} in -lical... " >&6; }
  16965. if eval \${$as_ac_Lib+:} false; then :
  16966. $as_echo_n "(cached) " >&6
  16967. else
  16968. ac_check_lib_save_LIBS=$LIBS
  16969. LIBS="-lical ${pbxlibdir} ${PTHREAD_LIBS} $LIBS"
  16970. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  16971. /* end confdefs.h. */
  16972. /* Override any GCC internal prototype to avoid an error.
  16973. Use char because int might match the return type of a GCC
  16974. builtin and then its argument prototype would still apply. */
  16975. #ifdef __cplusplus
  16976. extern "C"
  16977. #endif
  16978. char ${pbxfuncname} ();
  16979. int
  16980. main ()
  16981. {
  16982. return ${pbxfuncname} ();
  16983. ;
  16984. return 0;
  16985. }
  16986. _ACEOF
  16987. if ac_fn_c_try_link "$LINENO"; then :
  16988. eval "$as_ac_Lib=yes"
  16989. else
  16990. eval "$as_ac_Lib=no"
  16991. fi
  16992. rm -f core conftest.err conftest.$ac_objext \
  16993. conftest$ac_exeext conftest.$ac_ext
  16994. LIBS=$ac_check_lib_save_LIBS
  16995. fi
  16996. eval ac_res=\$$as_ac_Lib
  16997. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  16998. $as_echo "$ac_res" >&6; }
  16999. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17000. AST_ICAL_FOUND=yes
  17001. else
  17002. AST_ICAL_FOUND=no
  17003. fi
  17004. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17005. fi
  17006. # now check for the header.
  17007. if test "${AST_ICAL_FOUND}" = "yes"; then
  17008. ICAL_LIB="${pbxlibdir} -lical ${PTHREAD_LIBS}"
  17009. # if --with-ICAL=DIR has been specified, use it.
  17010. if test "x${ICAL_DIR}" != "x"; then
  17011. ICAL_INCLUDE="-I${ICAL_DIR}/include"
  17012. fi
  17013. ICAL_INCLUDE="${ICAL_INCLUDE} ${PTHREAD_CFLAGS}"
  17014. if test "xlibical/ical.h" = "x" ; then # no header, assume found
  17015. ICAL_HEADER_FOUND="1"
  17016. else # check for the header
  17017. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17018. CPPFLAGS="${CPPFLAGS} ${ICAL_INCLUDE}"
  17019. ac_fn_c_check_header_mongrel "$LINENO" "libical/ical.h" "ac_cv_header_libical_ical_h" "$ac_includes_default"
  17020. if test "x$ac_cv_header_libical_ical_h" = xyes; then :
  17021. ICAL_HEADER_FOUND=1
  17022. else
  17023. ICAL_HEADER_FOUND=0
  17024. fi
  17025. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17026. fi
  17027. if test "x${ICAL_HEADER_FOUND}" = "x0" ; then
  17028. ICAL_LIB=""
  17029. ICAL_INCLUDE=""
  17030. else
  17031. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17032. ICAL_LIB=""
  17033. fi
  17034. PBX_ICAL=1
  17035. cat >>confdefs.h <<_ACEOF
  17036. #define HAVE_ICAL 1
  17037. _ACEOF
  17038. fi
  17039. fi
  17040. fi
  17041. if test "x${PBX_IKSEMEL}" != "x1" -a "${USE_IKSEMEL}" != "no"; then
  17042. pbxlibdir=""
  17043. # if --with-IKSEMEL=DIR has been specified, use it.
  17044. if test "x${IKSEMEL_DIR}" != "x"; then
  17045. if test -d ${IKSEMEL_DIR}/lib; then
  17046. pbxlibdir="-L${IKSEMEL_DIR}/lib"
  17047. else
  17048. pbxlibdir="-L${IKSEMEL_DIR}"
  17049. fi
  17050. fi
  17051. pbxfuncname="iks_start_sasl"
  17052. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17053. AST_IKSEMEL_FOUND=yes
  17054. else
  17055. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17056. CFLAGS="${CFLAGS} "
  17057. as_ac_Lib=`$as_echo "ac_cv_lib_iksemel_${pbxfuncname}" | $as_tr_sh`
  17058. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liksemel" >&5
  17059. $as_echo_n "checking for ${pbxfuncname} in -liksemel... " >&6; }
  17060. if eval \${$as_ac_Lib+:} false; then :
  17061. $as_echo_n "(cached) " >&6
  17062. else
  17063. ac_check_lib_save_LIBS=$LIBS
  17064. LIBS="-liksemel ${pbxlibdir} $LIBS"
  17065. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17066. /* end confdefs.h. */
  17067. /* Override any GCC internal prototype to avoid an error.
  17068. Use char because int might match the return type of a GCC
  17069. builtin and then its argument prototype would still apply. */
  17070. #ifdef __cplusplus
  17071. extern "C"
  17072. #endif
  17073. char ${pbxfuncname} ();
  17074. int
  17075. main ()
  17076. {
  17077. return ${pbxfuncname} ();
  17078. ;
  17079. return 0;
  17080. }
  17081. _ACEOF
  17082. if ac_fn_c_try_link "$LINENO"; then :
  17083. eval "$as_ac_Lib=yes"
  17084. else
  17085. eval "$as_ac_Lib=no"
  17086. fi
  17087. rm -f core conftest.err conftest.$ac_objext \
  17088. conftest$ac_exeext conftest.$ac_ext
  17089. LIBS=$ac_check_lib_save_LIBS
  17090. fi
  17091. eval ac_res=\$$as_ac_Lib
  17092. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17093. $as_echo "$ac_res" >&6; }
  17094. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17095. AST_IKSEMEL_FOUND=yes
  17096. else
  17097. AST_IKSEMEL_FOUND=no
  17098. fi
  17099. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17100. fi
  17101. # now check for the header.
  17102. if test "${AST_IKSEMEL_FOUND}" = "yes"; then
  17103. IKSEMEL_LIB="${pbxlibdir} -liksemel "
  17104. # if --with-IKSEMEL=DIR has been specified, use it.
  17105. if test "x${IKSEMEL_DIR}" != "x"; then
  17106. IKSEMEL_INCLUDE="-I${IKSEMEL_DIR}/include"
  17107. fi
  17108. IKSEMEL_INCLUDE="${IKSEMEL_INCLUDE} "
  17109. if test "xiksemel.h" = "x" ; then # no header, assume found
  17110. IKSEMEL_HEADER_FOUND="1"
  17111. else # check for the header
  17112. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17113. CPPFLAGS="${CPPFLAGS} ${IKSEMEL_INCLUDE}"
  17114. ac_fn_c_check_header_mongrel "$LINENO" "iksemel.h" "ac_cv_header_iksemel_h" "$ac_includes_default"
  17115. if test "x$ac_cv_header_iksemel_h" = xyes; then :
  17116. IKSEMEL_HEADER_FOUND=1
  17117. else
  17118. IKSEMEL_HEADER_FOUND=0
  17119. fi
  17120. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17121. fi
  17122. if test "x${IKSEMEL_HEADER_FOUND}" = "x0" ; then
  17123. IKSEMEL_LIB=""
  17124. IKSEMEL_INCLUDE=""
  17125. else
  17126. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17127. IKSEMEL_LIB=""
  17128. fi
  17129. PBX_IKSEMEL=1
  17130. cat >>confdefs.h <<_ACEOF
  17131. #define HAVE_IKSEMEL 1
  17132. _ACEOF
  17133. fi
  17134. fi
  17135. fi
  17136. if test "${USE_IMAP_TK}" != "no"; then
  17137. saved_cppflags="${CPPFLAGS}"
  17138. saved_libs="${LIBS}"
  17139. switch_to_system_on_failure="no"
  17140. if test "${IMAP_TK_DIR}" = ""; then
  17141. IMAP_TK_DIR=`pwd`"/../imap-2004g"
  17142. switch_to_system_on_failure="yes"
  17143. fi
  17144. if test "${IMAP_TK_DIR}" != "system"; then
  17145. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UW IMAP Toolkit c-client library" >&5
  17146. $as_echo_n "checking for UW IMAP Toolkit c-client library... " >&6; }
  17147. if test -f "${IMAP_TK_DIR}/c-client/LDFLAGS"; then
  17148. imap_ldflags=`cat ${IMAP_TK_DIR}/c-client/LDFLAGS`
  17149. fi
  17150. imap_libs="${IMAP_TK_DIR}/c-client/c-client.a"
  17151. imap_include="-I${IMAP_TK_DIR}/c-client"
  17152. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17153. LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
  17154. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17155. /* end confdefs.h. */
  17156. #include "c-client.h"
  17157. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17158. {
  17159. }
  17160. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17161. {
  17162. }
  17163. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17164. {
  17165. }
  17166. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17167. {
  17168. }
  17169. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17170. {
  17171. }
  17172. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17173. {
  17174. }
  17175. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17176. {
  17177. }
  17178. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17179. {
  17180. }
  17181. void mm_log (char *string,long errflg)
  17182. {
  17183. }
  17184. void mm_dlog (char *string)
  17185. {
  17186. }
  17187. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17188. {
  17189. }
  17190. void mm_critical (MAILSTREAM *stream)
  17191. {
  17192. }
  17193. void mm_nocritical (MAILSTREAM *stream)
  17194. {
  17195. }
  17196. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17197. {
  17198. }
  17199. void mm_fatal (char *string)
  17200. {
  17201. }
  17202. int
  17203. main ()
  17204. {
  17205. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17206. ;
  17207. return 0;
  17208. }
  17209. _ACEOF
  17210. if ac_fn_c_try_link "$LINENO"; then :
  17211. ac_cv_imap_tk="yes"
  17212. else
  17213. ac_cv_imap_tk="no"
  17214. fi
  17215. rm -f core conftest.err conftest.$ac_objext \
  17216. conftest$ac_exeext conftest.$ac_ext
  17217. if test "${ac_cv_imap_tk}" = "yes"; then
  17218. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17219. /* end confdefs.h. */
  17220. #include "c-client.h"
  17221. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17222. {
  17223. }
  17224. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17225. {
  17226. }
  17227. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17228. {
  17229. }
  17230. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17231. {
  17232. }
  17233. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17234. {
  17235. }
  17236. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17237. {
  17238. }
  17239. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17240. {
  17241. }
  17242. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17243. {
  17244. }
  17245. void mm_log (char *string,long errflg)
  17246. {
  17247. }
  17248. void mm_dlog (char *string)
  17249. {
  17250. }
  17251. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17252. {
  17253. }
  17254. void mm_critical (MAILSTREAM *stream)
  17255. {
  17256. }
  17257. void mm_nocritical (MAILSTREAM *stream)
  17258. {
  17259. }
  17260. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17261. {
  17262. }
  17263. void mm_fatal (char *string)
  17264. {
  17265. }
  17266. int
  17267. main ()
  17268. {
  17269. long check = mail_expunge_full(NULL, "", 0);
  17270. ;
  17271. return 0;
  17272. }
  17273. _ACEOF
  17274. if ac_fn_c_try_link "$LINENO"; then :
  17275. ac_cv_imap_tk2006="yes"
  17276. else
  17277. ac_cv_imap_tk2006="no"
  17278. fi
  17279. rm -f core conftest.err conftest.$ac_objext \
  17280. conftest$ac_exeext conftest.$ac_ext
  17281. fi
  17282. CPPFLAGS="${saved_cppflags}"
  17283. LIBS="${saved_libs}"
  17284. if test "${ac_cv_imap_tk}" = "no"; then
  17285. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  17286. $as_echo "no" >&6; }
  17287. if test "${switch_to_system_on_failure}" = "yes"; then
  17288. IMAP_TK_DIR="system"
  17289. else #This means they specified a directory. Search for a package installation there too
  17290. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for system c-client library..." >&5
  17291. $as_echo_n "checking for system c-client library...... " >&6; }
  17292. CPPFLAGS="${saved_cppflags}"
  17293. LIBS="${saved_libs}"
  17294. imap_include="-I${IMAP_TK_DIR}/include"
  17295. imap_ldflags="-L${IMAP_TK_DIR}/lib"
  17296. imap_libs="-lc-client"
  17297. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17298. LIBS="${LIBS} ${imap_libs} ${imap_ldflags}"
  17299. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17300. /* end confdefs.h. */
  17301. #include "c-client.h"
  17302. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17303. {
  17304. }
  17305. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17306. {
  17307. }
  17308. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17309. {
  17310. }
  17311. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17312. {
  17313. }
  17314. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17315. {
  17316. }
  17317. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17318. {
  17319. }
  17320. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17321. {
  17322. }
  17323. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17324. {
  17325. }
  17326. void mm_log (char *string,long errflg)
  17327. {
  17328. }
  17329. void mm_dlog (char *string)
  17330. {
  17331. }
  17332. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17333. {
  17334. }
  17335. void mm_critical (MAILSTREAM *stream)
  17336. {
  17337. }
  17338. void mm_nocritical (MAILSTREAM *stream)
  17339. {
  17340. }
  17341. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17342. {
  17343. }
  17344. void mm_fatal (char *string)
  17345. {
  17346. }
  17347. int
  17348. main ()
  17349. {
  17350. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17351. ;
  17352. return 0;
  17353. }
  17354. _ACEOF
  17355. if ac_fn_c_try_link "$LINENO"; then :
  17356. ac_cv_imap_tk="yes"
  17357. else
  17358. ac_cv_imap_tk="no"
  17359. fi
  17360. rm -f core conftest.err conftest.$ac_objext \
  17361. conftest$ac_exeext conftest.$ac_ext
  17362. if test "${ac_cv_imap_tk}" = "yes"; then
  17363. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17364. /* end confdefs.h. */
  17365. #include "c-client.h"
  17366. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17367. {
  17368. }
  17369. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17370. {
  17371. }
  17372. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17373. {
  17374. }
  17375. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17376. {
  17377. }
  17378. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17379. {
  17380. }
  17381. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17382. {
  17383. }
  17384. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17385. {
  17386. }
  17387. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17388. {
  17389. }
  17390. void mm_log (char *string,long errflg)
  17391. {
  17392. }
  17393. void mm_dlog (char *string)
  17394. {
  17395. }
  17396. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17397. {
  17398. }
  17399. void mm_critical (MAILSTREAM *stream)
  17400. {
  17401. }
  17402. void mm_nocritical (MAILSTREAM *stream)
  17403. {
  17404. }
  17405. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17406. {
  17407. }
  17408. void mm_fatal (char *string)
  17409. {
  17410. }
  17411. int
  17412. main ()
  17413. {
  17414. long check = mail_expunge_full(NULL, "", 0);
  17415. ;
  17416. return 0;
  17417. }
  17418. _ACEOF
  17419. if ac_fn_c_try_link "$LINENO"; then :
  17420. ac_cv_imap_tk2006="yes"
  17421. else
  17422. ac_cv_imap_tk2006="no"
  17423. fi
  17424. rm -f core conftest.err conftest.$ac_objext \
  17425. conftest$ac_exeext conftest.$ac_ext
  17426. fi
  17427. fi
  17428. fi
  17429. fi
  17430. if test "${IMAP_TK_DIR}" = "system"; then
  17431. #We will enter here if user specified "system" or if any of above checks failed
  17432. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for system c-client library..." >&5
  17433. $as_echo_n "checking for system c-client library...... " >&6; }
  17434. CPPFLAGS="${saved_cppflags}"
  17435. LIBS="${saved_libs}"
  17436. imap_ldflags=""
  17437. imap_libs="-lc-client"
  17438. imap_include="-DUSE_SYSTEM_IMAP" #Try the imap directory first
  17439. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17440. LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
  17441. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17442. /* end confdefs.h. */
  17443. #include <stdio.h>
  17444. #include <imap/c-client.h>
  17445. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17446. {
  17447. }
  17448. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17449. {
  17450. }
  17451. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17452. {
  17453. }
  17454. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17455. {
  17456. }
  17457. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17458. {
  17459. }
  17460. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17461. {
  17462. }
  17463. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17464. {
  17465. }
  17466. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17467. {
  17468. }
  17469. void mm_log (char *string,long errflg)
  17470. {
  17471. }
  17472. void mm_dlog (char *string)
  17473. {
  17474. }
  17475. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17476. {
  17477. }
  17478. void mm_critical (MAILSTREAM *stream)
  17479. {
  17480. }
  17481. void mm_nocritical (MAILSTREAM *stream)
  17482. {
  17483. }
  17484. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17485. {
  17486. }
  17487. void mm_fatal (char *string)
  17488. {
  17489. }
  17490. int
  17491. main ()
  17492. {
  17493. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17494. ;
  17495. return 0;
  17496. }
  17497. _ACEOF
  17498. if ac_fn_c_try_link "$LINENO"; then :
  17499. ac_cv_imap_tk="yes"
  17500. else
  17501. ac_cv_imap_tk="no"
  17502. fi
  17503. rm -f core conftest.err conftest.$ac_objext \
  17504. conftest$ac_exeext conftest.$ac_ext
  17505. if test "${ac_cv_imap_tk}" = "yes"; then
  17506. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17507. /* end confdefs.h. */
  17508. #include <stdio.h>
  17509. #include <imap/c-client.h>
  17510. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17511. {
  17512. }
  17513. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17514. {
  17515. }
  17516. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17517. {
  17518. }
  17519. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17520. {
  17521. }
  17522. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17523. {
  17524. }
  17525. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17526. {
  17527. }
  17528. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17529. {
  17530. }
  17531. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17532. {
  17533. }
  17534. void mm_log (char *string,long errflg)
  17535. {
  17536. }
  17537. void mm_dlog (char *string)
  17538. {
  17539. }
  17540. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17541. {
  17542. }
  17543. void mm_critical (MAILSTREAM *stream)
  17544. {
  17545. }
  17546. void mm_nocritical (MAILSTREAM *stream)
  17547. {
  17548. }
  17549. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17550. {
  17551. }
  17552. void mm_fatal (char *string)
  17553. {
  17554. }
  17555. int
  17556. main ()
  17557. {
  17558. long check = mail_expunge_full(NULL, "", 0);
  17559. ;
  17560. return 0;
  17561. }
  17562. _ACEOF
  17563. if ac_fn_c_try_link "$LINENO"; then :
  17564. ac_cv_imap_tk2006="yes"
  17565. else
  17566. ac_cv_imap_tk2006="no"
  17567. fi
  17568. rm -f core conftest.err conftest.$ac_objext \
  17569. conftest$ac_exeext conftest.$ac_ext
  17570. else #looking in imap directory didn't work, try c-client
  17571. imap_ldflags=""
  17572. imap_libs="-lc-client"
  17573. imap_include="-DUSE_SYSTEM_CCLIENT"
  17574. CPPFLAGS="${saved_cppflags}"
  17575. LIBS="${saved_libs}"
  17576. CPPFLAGS="${CPPFLAGS} ${imap_include}"
  17577. LIBS="${LIBS} ${imap_libs} "`echo ${imap_ldflags}`
  17578. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17579. /* end confdefs.h. */
  17580. #include <stdio.h>
  17581. #include <c-client/c-client.h>
  17582. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17583. {
  17584. }
  17585. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17586. {
  17587. }
  17588. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17589. {
  17590. }
  17591. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17592. {
  17593. }
  17594. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17595. {
  17596. }
  17597. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17598. {
  17599. }
  17600. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17601. {
  17602. }
  17603. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17604. {
  17605. }
  17606. void mm_log (char *string,long errflg)
  17607. {
  17608. }
  17609. void mm_dlog (char *string)
  17610. {
  17611. }
  17612. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17613. {
  17614. }
  17615. void mm_critical (MAILSTREAM *stream)
  17616. {
  17617. }
  17618. void mm_nocritical (MAILSTREAM *stream)
  17619. {
  17620. }
  17621. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17622. {
  17623. }
  17624. void mm_fatal (char *string)
  17625. {
  17626. }
  17627. int
  17628. main ()
  17629. {
  17630. MAILSTREAM *foo = mail_open(NULL, "", 0);
  17631. ;
  17632. return 0;
  17633. }
  17634. _ACEOF
  17635. if ac_fn_c_try_link "$LINENO"; then :
  17636. ac_cv_imap_tk="yes"
  17637. else
  17638. ac_cv_imap_tk="no"
  17639. fi
  17640. rm -f core conftest.err conftest.$ac_objext \
  17641. conftest$ac_exeext conftest.$ac_ext
  17642. if test "${ac_cv_imap_tk}" = "yes"; then
  17643. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17644. /* end confdefs.h. */
  17645. #include <stdio.h>
  17646. #include <c-client/c-client.h>
  17647. void mm_searched (MAILSTREAM *stream,unsigned long number)
  17648. {
  17649. }
  17650. void mm_exists (MAILSTREAM *stream,unsigned long number)
  17651. {
  17652. }
  17653. void mm_expunged (MAILSTREAM *stream,unsigned long number)
  17654. {
  17655. }
  17656. void mm_flags (MAILSTREAM *stream,unsigned long number)
  17657. {
  17658. }
  17659. void mm_notify (MAILSTREAM *stream,char *string,long errflg)
  17660. {
  17661. }
  17662. void mm_list (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17663. {
  17664. }
  17665. void mm_lsub (MAILSTREAM *stream,int delimiter,char *mailbox,long attributes)
  17666. {
  17667. }
  17668. void mm_status (MAILSTREAM *stream,char *mailbox,MAILSTATUS *status)
  17669. {
  17670. }
  17671. void mm_log (char *string,long errflg)
  17672. {
  17673. }
  17674. void mm_dlog (char *string)
  17675. {
  17676. }
  17677. void mm_login (NETMBX *mb,char *user,char *pwd,long trial)
  17678. {
  17679. }
  17680. void mm_critical (MAILSTREAM *stream)
  17681. {
  17682. }
  17683. void mm_nocritical (MAILSTREAM *stream)
  17684. {
  17685. }
  17686. long mm_diskerror (MAILSTREAM *stream,long errcode,long serious)
  17687. {
  17688. }
  17689. void mm_fatal (char *string)
  17690. {
  17691. }
  17692. int
  17693. main ()
  17694. {
  17695. long check = mail_expunge_full(NULL, "", 0);
  17696. ;
  17697. return 0;
  17698. }
  17699. _ACEOF
  17700. if ac_fn_c_try_link "$LINENO"; then :
  17701. ac_cv_imap_tk2006="yes"
  17702. else
  17703. ac_cv_imap_tk2006="no"
  17704. fi
  17705. rm -f core conftest.err conftest.$ac_objext \
  17706. conftest$ac_exeext conftest.$ac_ext
  17707. fi
  17708. fi
  17709. fi
  17710. if test "${ac_cv_imap_tk}" = "yes"; then
  17711. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  17712. $as_echo "yes" >&6; }
  17713. IMAP_TK_LIB="${imap_libs} "`echo ${imap_ldflags}`
  17714. IMAP_TK_INCLUDE="${imap_include}"
  17715. PBX_IMAP_TK=1
  17716. $as_echo "#define HAVE_IMAP_TK 1" >>confdefs.h
  17717. if test "${ac_cv_imap_tk2006}" = "yes"; then
  17718. $as_echo "#define HAVE_IMAP_TK2006 1" >>confdefs.h
  17719. fi
  17720. else
  17721. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  17722. $as_echo "no" >&6; }
  17723. fi
  17724. CPPFLAGS="${saved_cppflags}"
  17725. LIBS="${saved_libs}"
  17726. fi
  17727. if test "x${PBX_IODBC}" != "x1" -a "${USE_IODBC}" != "no"; then
  17728. pbxlibdir=""
  17729. # if --with-IODBC=DIR has been specified, use it.
  17730. if test "x${IODBC_DIR}" != "x"; then
  17731. if test -d ${IODBC_DIR}/lib; then
  17732. pbxlibdir="-L${IODBC_DIR}/lib"
  17733. else
  17734. pbxlibdir="-L${IODBC_DIR}"
  17735. fi
  17736. fi
  17737. pbxfuncname="SQLConnect"
  17738. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17739. AST_IODBC_FOUND=yes
  17740. else
  17741. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17742. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  17743. as_ac_Lib=`$as_echo "ac_cv_lib_iodbc_${pbxfuncname}" | $as_tr_sh`
  17744. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -liodbc" >&5
  17745. $as_echo_n "checking for ${pbxfuncname} in -liodbc... " >&6; }
  17746. if eval \${$as_ac_Lib+:} false; then :
  17747. $as_echo_n "(cached) " >&6
  17748. else
  17749. ac_check_lib_save_LIBS=$LIBS
  17750. LIBS="-liodbc ${pbxlibdir} ${PTHREAD_LIBS} $LIBS"
  17751. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17752. /* end confdefs.h. */
  17753. /* Override any GCC internal prototype to avoid an error.
  17754. Use char because int might match the return type of a GCC
  17755. builtin and then its argument prototype would still apply. */
  17756. #ifdef __cplusplus
  17757. extern "C"
  17758. #endif
  17759. char ${pbxfuncname} ();
  17760. int
  17761. main ()
  17762. {
  17763. return ${pbxfuncname} ();
  17764. ;
  17765. return 0;
  17766. }
  17767. _ACEOF
  17768. if ac_fn_c_try_link "$LINENO"; then :
  17769. eval "$as_ac_Lib=yes"
  17770. else
  17771. eval "$as_ac_Lib=no"
  17772. fi
  17773. rm -f core conftest.err conftest.$ac_objext \
  17774. conftest$ac_exeext conftest.$ac_ext
  17775. LIBS=$ac_check_lib_save_LIBS
  17776. fi
  17777. eval ac_res=\$$as_ac_Lib
  17778. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17779. $as_echo "$ac_res" >&6; }
  17780. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17781. AST_IODBC_FOUND=yes
  17782. else
  17783. AST_IODBC_FOUND=no
  17784. fi
  17785. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17786. fi
  17787. # now check for the header.
  17788. if test "${AST_IODBC_FOUND}" = "yes"; then
  17789. IODBC_LIB="${pbxlibdir} -liodbc ${PTHREAD_LIBS}"
  17790. # if --with-IODBC=DIR has been specified, use it.
  17791. if test "x${IODBC_DIR}" != "x"; then
  17792. IODBC_INCLUDE="-I${IODBC_DIR}/include"
  17793. fi
  17794. IODBC_INCLUDE="${IODBC_INCLUDE} ${PTHREAD_CFLAGS}"
  17795. if test "xsql.h" = "x" ; then # no header, assume found
  17796. IODBC_HEADER_FOUND="1"
  17797. else # check for the header
  17798. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17799. CPPFLAGS="${CPPFLAGS} ${IODBC_INCLUDE}"
  17800. ac_fn_c_check_header_mongrel "$LINENO" "sql.h" "ac_cv_header_sql_h" "$ac_includes_default"
  17801. if test "x$ac_cv_header_sql_h" = xyes; then :
  17802. IODBC_HEADER_FOUND=1
  17803. else
  17804. IODBC_HEADER_FOUND=0
  17805. fi
  17806. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17807. fi
  17808. if test "x${IODBC_HEADER_FOUND}" = "x0" ; then
  17809. IODBC_LIB=""
  17810. IODBC_INCLUDE=""
  17811. else
  17812. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17813. IODBC_LIB=""
  17814. fi
  17815. PBX_IODBC=1
  17816. cat >>confdefs.h <<_ACEOF
  17817. #define HAVE_IODBC 1
  17818. _ACEOF
  17819. fi
  17820. fi
  17821. fi
  17822. if test "x${PBX_INOTIFY}" != "x1" -a "${USE_INOTIFY}" != "no"; then
  17823. pbxlibdir=""
  17824. # if --with-INOTIFY=DIR has been specified, use it.
  17825. if test "x${INOTIFY_DIR}" != "x"; then
  17826. if test -d ${INOTIFY_DIR}/lib; then
  17827. pbxlibdir="-L${INOTIFY_DIR}/lib"
  17828. else
  17829. pbxlibdir="-L${INOTIFY_DIR}"
  17830. fi
  17831. fi
  17832. pbxfuncname="inotify_init"
  17833. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17834. AST_INOTIFY_FOUND=yes
  17835. else
  17836. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17837. CFLAGS="${CFLAGS} "
  17838. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  17839. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  17840. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  17841. if eval \${$as_ac_Lib+:} false; then :
  17842. $as_echo_n "(cached) " >&6
  17843. else
  17844. ac_check_lib_save_LIBS=$LIBS
  17845. LIBS="-lc ${pbxlibdir} $LIBS"
  17846. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17847. /* end confdefs.h. */
  17848. /* Override any GCC internal prototype to avoid an error.
  17849. Use char because int might match the return type of a GCC
  17850. builtin and then its argument prototype would still apply. */
  17851. #ifdef __cplusplus
  17852. extern "C"
  17853. #endif
  17854. char ${pbxfuncname} ();
  17855. int
  17856. main ()
  17857. {
  17858. return ${pbxfuncname} ();
  17859. ;
  17860. return 0;
  17861. }
  17862. _ACEOF
  17863. if ac_fn_c_try_link "$LINENO"; then :
  17864. eval "$as_ac_Lib=yes"
  17865. else
  17866. eval "$as_ac_Lib=no"
  17867. fi
  17868. rm -f core conftest.err conftest.$ac_objext \
  17869. conftest$ac_exeext conftest.$ac_ext
  17870. LIBS=$ac_check_lib_save_LIBS
  17871. fi
  17872. eval ac_res=\$$as_ac_Lib
  17873. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17874. $as_echo "$ac_res" >&6; }
  17875. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17876. AST_INOTIFY_FOUND=yes
  17877. else
  17878. AST_INOTIFY_FOUND=no
  17879. fi
  17880. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17881. fi
  17882. # now check for the header.
  17883. if test "${AST_INOTIFY_FOUND}" = "yes"; then
  17884. INOTIFY_LIB="${pbxlibdir} -lc "
  17885. # if --with-INOTIFY=DIR has been specified, use it.
  17886. if test "x${INOTIFY_DIR}" != "x"; then
  17887. INOTIFY_INCLUDE="-I${INOTIFY_DIR}/include"
  17888. fi
  17889. INOTIFY_INCLUDE="${INOTIFY_INCLUDE} "
  17890. if test "xsys/inotify.h" = "x" ; then # no header, assume found
  17891. INOTIFY_HEADER_FOUND="1"
  17892. else # check for the header
  17893. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17894. CPPFLAGS="${CPPFLAGS} ${INOTIFY_INCLUDE}"
  17895. ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
  17896. if test "x$ac_cv_header_sys_inotify_h" = xyes; then :
  17897. INOTIFY_HEADER_FOUND=1
  17898. else
  17899. INOTIFY_HEADER_FOUND=0
  17900. fi
  17901. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17902. fi
  17903. if test "x${INOTIFY_HEADER_FOUND}" = "x0" ; then
  17904. INOTIFY_LIB=""
  17905. INOTIFY_INCLUDE=""
  17906. else
  17907. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  17908. INOTIFY_LIB=""
  17909. fi
  17910. PBX_INOTIFY=1
  17911. cat >>confdefs.h <<_ACEOF
  17912. #define HAVE_INOTIFY 1
  17913. _ACEOF
  17914. fi
  17915. fi
  17916. fi
  17917. if test "x${PBX_JACK}" != "x1" -a "${USE_JACK}" != "no"; then
  17918. pbxlibdir=""
  17919. # if --with-JACK=DIR has been specified, use it.
  17920. if test "x${JACK_DIR}" != "x"; then
  17921. if test -d ${JACK_DIR}/lib; then
  17922. pbxlibdir="-L${JACK_DIR}/lib"
  17923. else
  17924. pbxlibdir="-L${JACK_DIR}"
  17925. fi
  17926. fi
  17927. pbxfuncname="jack_activate"
  17928. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  17929. AST_JACK_FOUND=yes
  17930. else
  17931. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  17932. CFLAGS="${CFLAGS} "
  17933. as_ac_Lib=`$as_echo "ac_cv_lib_jack_${pbxfuncname}" | $as_tr_sh`
  17934. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ljack" >&5
  17935. $as_echo_n "checking for ${pbxfuncname} in -ljack... " >&6; }
  17936. if eval \${$as_ac_Lib+:} false; then :
  17937. $as_echo_n "(cached) " >&6
  17938. else
  17939. ac_check_lib_save_LIBS=$LIBS
  17940. LIBS="-ljack ${pbxlibdir} $LIBS"
  17941. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  17942. /* end confdefs.h. */
  17943. /* Override any GCC internal prototype to avoid an error.
  17944. Use char because int might match the return type of a GCC
  17945. builtin and then its argument prototype would still apply. */
  17946. #ifdef __cplusplus
  17947. extern "C"
  17948. #endif
  17949. char ${pbxfuncname} ();
  17950. int
  17951. main ()
  17952. {
  17953. return ${pbxfuncname} ();
  17954. ;
  17955. return 0;
  17956. }
  17957. _ACEOF
  17958. if ac_fn_c_try_link "$LINENO"; then :
  17959. eval "$as_ac_Lib=yes"
  17960. else
  17961. eval "$as_ac_Lib=no"
  17962. fi
  17963. rm -f core conftest.err conftest.$ac_objext \
  17964. conftest$ac_exeext conftest.$ac_ext
  17965. LIBS=$ac_check_lib_save_LIBS
  17966. fi
  17967. eval ac_res=\$$as_ac_Lib
  17968. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  17969. $as_echo "$ac_res" >&6; }
  17970. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  17971. AST_JACK_FOUND=yes
  17972. else
  17973. AST_JACK_FOUND=no
  17974. fi
  17975. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  17976. fi
  17977. # now check for the header.
  17978. if test "${AST_JACK_FOUND}" = "yes"; then
  17979. JACK_LIB="${pbxlibdir} -ljack "
  17980. # if --with-JACK=DIR has been specified, use it.
  17981. if test "x${JACK_DIR}" != "x"; then
  17982. JACK_INCLUDE="-I${JACK_DIR}/include"
  17983. fi
  17984. JACK_INCLUDE="${JACK_INCLUDE} "
  17985. if test "xjack/jack.h" = "x" ; then # no header, assume found
  17986. JACK_HEADER_FOUND="1"
  17987. else # check for the header
  17988. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  17989. CPPFLAGS="${CPPFLAGS} ${JACK_INCLUDE}"
  17990. ac_fn_c_check_header_mongrel "$LINENO" "jack/jack.h" "ac_cv_header_jack_jack_h" "$ac_includes_default"
  17991. if test "x$ac_cv_header_jack_jack_h" = xyes; then :
  17992. JACK_HEADER_FOUND=1
  17993. else
  17994. JACK_HEADER_FOUND=0
  17995. fi
  17996. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  17997. fi
  17998. if test "x${JACK_HEADER_FOUND}" = "x0" ; then
  17999. JACK_LIB=""
  18000. JACK_INCLUDE=""
  18001. else
  18002. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18003. JACK_LIB=""
  18004. fi
  18005. PBX_JACK=1
  18006. cat >>confdefs.h <<_ACEOF
  18007. #define HAVE_JACK 1
  18008. _ACEOF
  18009. fi
  18010. fi
  18011. fi
  18012. # BSD (and OS X) equivalent of inotify
  18013. if test "x${PBX_KQUEUE}" != "x1" -a "${USE_KQUEUE}" != "no"; then
  18014. pbxlibdir=""
  18015. # if --with-KQUEUE=DIR has been specified, use it.
  18016. if test "x${KQUEUE_DIR}" != "x"; then
  18017. if test -d ${KQUEUE_DIR}/lib; then
  18018. pbxlibdir="-L${KQUEUE_DIR}/lib"
  18019. else
  18020. pbxlibdir="-L${KQUEUE_DIR}"
  18021. fi
  18022. fi
  18023. pbxfuncname="kqueue"
  18024. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18025. AST_KQUEUE_FOUND=yes
  18026. else
  18027. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18028. CFLAGS="${CFLAGS} "
  18029. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  18030. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  18031. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  18032. if eval \${$as_ac_Lib+:} false; then :
  18033. $as_echo_n "(cached) " >&6
  18034. else
  18035. ac_check_lib_save_LIBS=$LIBS
  18036. LIBS="-lc ${pbxlibdir} $LIBS"
  18037. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18038. /* end confdefs.h. */
  18039. /* Override any GCC internal prototype to avoid an error.
  18040. Use char because int might match the return type of a GCC
  18041. builtin and then its argument prototype would still apply. */
  18042. #ifdef __cplusplus
  18043. extern "C"
  18044. #endif
  18045. char ${pbxfuncname} ();
  18046. int
  18047. main ()
  18048. {
  18049. return ${pbxfuncname} ();
  18050. ;
  18051. return 0;
  18052. }
  18053. _ACEOF
  18054. if ac_fn_c_try_link "$LINENO"; then :
  18055. eval "$as_ac_Lib=yes"
  18056. else
  18057. eval "$as_ac_Lib=no"
  18058. fi
  18059. rm -f core conftest.err conftest.$ac_objext \
  18060. conftest$ac_exeext conftest.$ac_ext
  18061. LIBS=$ac_check_lib_save_LIBS
  18062. fi
  18063. eval ac_res=\$$as_ac_Lib
  18064. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18065. $as_echo "$ac_res" >&6; }
  18066. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18067. AST_KQUEUE_FOUND=yes
  18068. else
  18069. AST_KQUEUE_FOUND=no
  18070. fi
  18071. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18072. fi
  18073. # now check for the header.
  18074. if test "${AST_KQUEUE_FOUND}" = "yes"; then
  18075. KQUEUE_LIB="${pbxlibdir} -lc "
  18076. # if --with-KQUEUE=DIR has been specified, use it.
  18077. if test "x${KQUEUE_DIR}" != "x"; then
  18078. KQUEUE_INCLUDE="-I${KQUEUE_DIR}/include"
  18079. fi
  18080. KQUEUE_INCLUDE="${KQUEUE_INCLUDE} "
  18081. if test "xsys/event.h" = "x" ; then # no header, assume found
  18082. KQUEUE_HEADER_FOUND="1"
  18083. else # check for the header
  18084. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18085. CPPFLAGS="${CPPFLAGS} ${KQUEUE_INCLUDE}"
  18086. ac_fn_c_check_header_mongrel "$LINENO" "sys/event.h" "ac_cv_header_sys_event_h" "$ac_includes_default"
  18087. if test "x$ac_cv_header_sys_event_h" = xyes; then :
  18088. KQUEUE_HEADER_FOUND=1
  18089. else
  18090. KQUEUE_HEADER_FOUND=0
  18091. fi
  18092. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18093. fi
  18094. if test "x${KQUEUE_HEADER_FOUND}" = "x0" ; then
  18095. KQUEUE_LIB=""
  18096. KQUEUE_INCLUDE=""
  18097. else
  18098. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18099. KQUEUE_LIB=""
  18100. fi
  18101. PBX_KQUEUE=1
  18102. cat >>confdefs.h <<_ACEOF
  18103. #define HAVE_KQUEUE 1
  18104. _ACEOF
  18105. fi
  18106. fi
  18107. fi
  18108. # 64-bit version of kevent (from kqueue) on OS X
  18109. for ac_func in kevent64
  18110. do :
  18111. ac_fn_c_check_func "$LINENO" "kevent64" "ac_cv_func_kevent64"
  18112. if test "x$ac_cv_func_kevent64" = xyes; then :
  18113. cat >>confdefs.h <<_ACEOF
  18114. #define HAVE_KEVENT64 1
  18115. _ACEOF
  18116. fi
  18117. done
  18118. # Needed by unixodbc
  18119. if test "x${PBX_LTDL}" != "x1" -a "${USE_LTDL}" != "no"; then
  18120. pbxlibdir=""
  18121. # if --with-LTDL=DIR has been specified, use it.
  18122. if test "x${LTDL_DIR}" != "x"; then
  18123. if test -d ${LTDL_DIR}/lib; then
  18124. pbxlibdir="-L${LTDL_DIR}/lib"
  18125. else
  18126. pbxlibdir="-L${LTDL_DIR}"
  18127. fi
  18128. fi
  18129. pbxfuncname="lt_dlinit"
  18130. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18131. AST_LTDL_FOUND=yes
  18132. else
  18133. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18134. CFLAGS="${CFLAGS} "
  18135. as_ac_Lib=`$as_echo "ac_cv_lib_ltdl_${pbxfuncname}" | $as_tr_sh`
  18136. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lltdl" >&5
  18137. $as_echo_n "checking for ${pbxfuncname} in -lltdl... " >&6; }
  18138. if eval \${$as_ac_Lib+:} false; then :
  18139. $as_echo_n "(cached) " >&6
  18140. else
  18141. ac_check_lib_save_LIBS=$LIBS
  18142. LIBS="-lltdl ${pbxlibdir} $LIBS"
  18143. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18144. /* end confdefs.h. */
  18145. /* Override any GCC internal prototype to avoid an error.
  18146. Use char because int might match the return type of a GCC
  18147. builtin and then its argument prototype would still apply. */
  18148. #ifdef __cplusplus
  18149. extern "C"
  18150. #endif
  18151. char ${pbxfuncname} ();
  18152. int
  18153. main ()
  18154. {
  18155. return ${pbxfuncname} ();
  18156. ;
  18157. return 0;
  18158. }
  18159. _ACEOF
  18160. if ac_fn_c_try_link "$LINENO"; then :
  18161. eval "$as_ac_Lib=yes"
  18162. else
  18163. eval "$as_ac_Lib=no"
  18164. fi
  18165. rm -f core conftest.err conftest.$ac_objext \
  18166. conftest$ac_exeext conftest.$ac_ext
  18167. LIBS=$ac_check_lib_save_LIBS
  18168. fi
  18169. eval ac_res=\$$as_ac_Lib
  18170. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18171. $as_echo "$ac_res" >&6; }
  18172. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18173. AST_LTDL_FOUND=yes
  18174. else
  18175. AST_LTDL_FOUND=no
  18176. fi
  18177. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18178. fi
  18179. # now check for the header.
  18180. if test "${AST_LTDL_FOUND}" = "yes"; then
  18181. LTDL_LIB="${pbxlibdir} -lltdl "
  18182. # if --with-LTDL=DIR has been specified, use it.
  18183. if test "x${LTDL_DIR}" != "x"; then
  18184. LTDL_INCLUDE="-I${LTDL_DIR}/include"
  18185. fi
  18186. LTDL_INCLUDE="${LTDL_INCLUDE} "
  18187. if test "xltdl.h" = "x" ; then # no header, assume found
  18188. LTDL_HEADER_FOUND="1"
  18189. else # check for the header
  18190. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18191. CPPFLAGS="${CPPFLAGS} ${LTDL_INCLUDE}"
  18192. ac_fn_c_check_header_mongrel "$LINENO" "ltdl.h" "ac_cv_header_ltdl_h" "$ac_includes_default"
  18193. if test "x$ac_cv_header_ltdl_h" = xyes; then :
  18194. LTDL_HEADER_FOUND=1
  18195. else
  18196. LTDL_HEADER_FOUND=0
  18197. fi
  18198. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18199. fi
  18200. if test "x${LTDL_HEADER_FOUND}" = "x0" ; then
  18201. LTDL_LIB=""
  18202. LTDL_INCLUDE=""
  18203. else
  18204. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18205. LTDL_LIB=""
  18206. fi
  18207. PBX_LTDL=1
  18208. cat >>confdefs.h <<_ACEOF
  18209. #define HAVE_LTDL 1
  18210. _ACEOF
  18211. fi
  18212. fi
  18213. fi
  18214. if test "x${PBX_LDAP}" != "x1" -a "${USE_LDAP}" != "no"; then
  18215. pbxlibdir=""
  18216. # if --with-LDAP=DIR has been specified, use it.
  18217. if test "x${LDAP_DIR}" != "x"; then
  18218. if test -d ${LDAP_DIR}/lib; then
  18219. pbxlibdir="-L${LDAP_DIR}/lib"
  18220. else
  18221. pbxlibdir="-L${LDAP_DIR}"
  18222. fi
  18223. fi
  18224. pbxfuncname="ldap_initialize"
  18225. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18226. AST_LDAP_FOUND=yes
  18227. else
  18228. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18229. CFLAGS="${CFLAGS} "
  18230. as_ac_Lib=`$as_echo "ac_cv_lib_ldap_${pbxfuncname}" | $as_tr_sh`
  18231. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lldap" >&5
  18232. $as_echo_n "checking for ${pbxfuncname} in -lldap... " >&6; }
  18233. if eval \${$as_ac_Lib+:} false; then :
  18234. $as_echo_n "(cached) " >&6
  18235. else
  18236. ac_check_lib_save_LIBS=$LIBS
  18237. LIBS="-lldap ${pbxlibdir} $LIBS"
  18238. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18239. /* end confdefs.h. */
  18240. /* Override any GCC internal prototype to avoid an error.
  18241. Use char because int might match the return type of a GCC
  18242. builtin and then its argument prototype would still apply. */
  18243. #ifdef __cplusplus
  18244. extern "C"
  18245. #endif
  18246. char ${pbxfuncname} ();
  18247. int
  18248. main ()
  18249. {
  18250. return ${pbxfuncname} ();
  18251. ;
  18252. return 0;
  18253. }
  18254. _ACEOF
  18255. if ac_fn_c_try_link "$LINENO"; then :
  18256. eval "$as_ac_Lib=yes"
  18257. else
  18258. eval "$as_ac_Lib=no"
  18259. fi
  18260. rm -f core conftest.err conftest.$ac_objext \
  18261. conftest$ac_exeext conftest.$ac_ext
  18262. LIBS=$ac_check_lib_save_LIBS
  18263. fi
  18264. eval ac_res=\$$as_ac_Lib
  18265. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18266. $as_echo "$ac_res" >&6; }
  18267. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18268. AST_LDAP_FOUND=yes
  18269. else
  18270. AST_LDAP_FOUND=no
  18271. fi
  18272. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18273. fi
  18274. # now check for the header.
  18275. if test "${AST_LDAP_FOUND}" = "yes"; then
  18276. LDAP_LIB="${pbxlibdir} -lldap "
  18277. # if --with-LDAP=DIR has been specified, use it.
  18278. if test "x${LDAP_DIR}" != "x"; then
  18279. LDAP_INCLUDE="-I${LDAP_DIR}/include"
  18280. fi
  18281. LDAP_INCLUDE="${LDAP_INCLUDE} "
  18282. if test "xldap.h" = "x" ; then # no header, assume found
  18283. LDAP_HEADER_FOUND="1"
  18284. else # check for the header
  18285. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18286. CPPFLAGS="${CPPFLAGS} ${LDAP_INCLUDE}"
  18287. ac_fn_c_check_header_mongrel "$LINENO" "ldap.h" "ac_cv_header_ldap_h" "$ac_includes_default"
  18288. if test "x$ac_cv_header_ldap_h" = xyes; then :
  18289. LDAP_HEADER_FOUND=1
  18290. else
  18291. LDAP_HEADER_FOUND=0
  18292. fi
  18293. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18294. fi
  18295. if test "x${LDAP_HEADER_FOUND}" = "x0" ; then
  18296. LDAP_LIB=""
  18297. LDAP_INCLUDE=""
  18298. else
  18299. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18300. LDAP_LIB=""
  18301. fi
  18302. PBX_LDAP=1
  18303. cat >>confdefs.h <<_ACEOF
  18304. #define HAVE_LDAP 1
  18305. _ACEOF
  18306. fi
  18307. fi
  18308. fi
  18309. if test "x${PBX_MISDN}" != "x1" -a "${USE_MISDN}" != "no"; then
  18310. pbxlibdir=""
  18311. # if --with-MISDN=DIR has been specified, use it.
  18312. if test "x${MISDN_DIR}" != "x"; then
  18313. if test -d ${MISDN_DIR}/lib; then
  18314. pbxlibdir="-L${MISDN_DIR}/lib"
  18315. else
  18316. pbxlibdir="-L${MISDN_DIR}"
  18317. fi
  18318. fi
  18319. pbxfuncname="mISDN_open"
  18320. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18321. AST_MISDN_FOUND=yes
  18322. else
  18323. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18324. CFLAGS="${CFLAGS} "
  18325. as_ac_Lib=`$as_echo "ac_cv_lib_mISDN_${pbxfuncname}" | $as_tr_sh`
  18326. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lmISDN" >&5
  18327. $as_echo_n "checking for ${pbxfuncname} in -lmISDN... " >&6; }
  18328. if eval \${$as_ac_Lib+:} false; then :
  18329. $as_echo_n "(cached) " >&6
  18330. else
  18331. ac_check_lib_save_LIBS=$LIBS
  18332. LIBS="-lmISDN ${pbxlibdir} $LIBS"
  18333. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18334. /* end confdefs.h. */
  18335. /* Override any GCC internal prototype to avoid an error.
  18336. Use char because int might match the return type of a GCC
  18337. builtin and then its argument prototype would still apply. */
  18338. #ifdef __cplusplus
  18339. extern "C"
  18340. #endif
  18341. char ${pbxfuncname} ();
  18342. int
  18343. main ()
  18344. {
  18345. return ${pbxfuncname} ();
  18346. ;
  18347. return 0;
  18348. }
  18349. _ACEOF
  18350. if ac_fn_c_try_link "$LINENO"; then :
  18351. eval "$as_ac_Lib=yes"
  18352. else
  18353. eval "$as_ac_Lib=no"
  18354. fi
  18355. rm -f core conftest.err conftest.$ac_objext \
  18356. conftest$ac_exeext conftest.$ac_ext
  18357. LIBS=$ac_check_lib_save_LIBS
  18358. fi
  18359. eval ac_res=\$$as_ac_Lib
  18360. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18361. $as_echo "$ac_res" >&6; }
  18362. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18363. AST_MISDN_FOUND=yes
  18364. else
  18365. AST_MISDN_FOUND=no
  18366. fi
  18367. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18368. fi
  18369. # now check for the header.
  18370. if test "${AST_MISDN_FOUND}" = "yes"; then
  18371. MISDN_LIB="${pbxlibdir} -lmISDN "
  18372. # if --with-MISDN=DIR has been specified, use it.
  18373. if test "x${MISDN_DIR}" != "x"; then
  18374. MISDN_INCLUDE="-I${MISDN_DIR}/include"
  18375. fi
  18376. MISDN_INCLUDE="${MISDN_INCLUDE} "
  18377. if test "xmISDNuser/mISDNlib.h" = "x" ; then # no header, assume found
  18378. MISDN_HEADER_FOUND="1"
  18379. else # check for the header
  18380. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18381. CPPFLAGS="${CPPFLAGS} ${MISDN_INCLUDE}"
  18382. ac_fn_c_check_header_mongrel "$LINENO" "mISDNuser/mISDNlib.h" "ac_cv_header_mISDNuser_mISDNlib_h" "$ac_includes_default"
  18383. if test "x$ac_cv_header_mISDNuser_mISDNlib_h" = xyes; then :
  18384. MISDN_HEADER_FOUND=1
  18385. else
  18386. MISDN_HEADER_FOUND=0
  18387. fi
  18388. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18389. fi
  18390. if test "x${MISDN_HEADER_FOUND}" = "x0" ; then
  18391. MISDN_LIB=""
  18392. MISDN_INCLUDE=""
  18393. else
  18394. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18395. MISDN_LIB=""
  18396. fi
  18397. PBX_MISDN=1
  18398. cat >>confdefs.h <<_ACEOF
  18399. #define HAVE_MISDN 1
  18400. _ACEOF
  18401. fi
  18402. fi
  18403. fi
  18404. if test "${PBX_MISDN}" = 1; then
  18405. if test "x${PBX_ISDNNET}" != "x1" -a "${USE_ISDNNET}" != "no"; then
  18406. pbxlibdir=""
  18407. # if --with-ISDNNET=DIR has been specified, use it.
  18408. if test "x${ISDNNET_DIR}" != "x"; then
  18409. if test -d ${ISDNNET_DIR}/lib; then
  18410. pbxlibdir="-L${ISDNNET_DIR}/lib"
  18411. else
  18412. pbxlibdir="-L${ISDNNET_DIR}"
  18413. fi
  18414. fi
  18415. pbxfuncname="init_manager"
  18416. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18417. AST_ISDNNET_FOUND=yes
  18418. else
  18419. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18420. CFLAGS="${CFLAGS} "
  18421. as_ac_Lib=`$as_echo "ac_cv_lib_isdnnet_${pbxfuncname}" | $as_tr_sh`
  18422. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lisdnnet" >&5
  18423. $as_echo_n "checking for ${pbxfuncname} in -lisdnnet... " >&6; }
  18424. if eval \${$as_ac_Lib+:} false; then :
  18425. $as_echo_n "(cached) " >&6
  18426. else
  18427. ac_check_lib_save_LIBS=$LIBS
  18428. LIBS="-lisdnnet ${pbxlibdir} -lmISDN -lpthread $LIBS"
  18429. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18430. /* end confdefs.h. */
  18431. /* Override any GCC internal prototype to avoid an error.
  18432. Use char because int might match the return type of a GCC
  18433. builtin and then its argument prototype would still apply. */
  18434. #ifdef __cplusplus
  18435. extern "C"
  18436. #endif
  18437. char ${pbxfuncname} ();
  18438. int
  18439. main ()
  18440. {
  18441. return ${pbxfuncname} ();
  18442. ;
  18443. return 0;
  18444. }
  18445. _ACEOF
  18446. if ac_fn_c_try_link "$LINENO"; then :
  18447. eval "$as_ac_Lib=yes"
  18448. else
  18449. eval "$as_ac_Lib=no"
  18450. fi
  18451. rm -f core conftest.err conftest.$ac_objext \
  18452. conftest$ac_exeext conftest.$ac_ext
  18453. LIBS=$ac_check_lib_save_LIBS
  18454. fi
  18455. eval ac_res=\$$as_ac_Lib
  18456. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18457. $as_echo "$ac_res" >&6; }
  18458. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18459. AST_ISDNNET_FOUND=yes
  18460. else
  18461. AST_ISDNNET_FOUND=no
  18462. fi
  18463. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18464. fi
  18465. # now check for the header.
  18466. if test "${AST_ISDNNET_FOUND}" = "yes"; then
  18467. ISDNNET_LIB="${pbxlibdir} -lisdnnet -lmISDN -lpthread"
  18468. # if --with-ISDNNET=DIR has been specified, use it.
  18469. if test "x${ISDNNET_DIR}" != "x"; then
  18470. ISDNNET_INCLUDE="-I${ISDNNET_DIR}/include"
  18471. fi
  18472. ISDNNET_INCLUDE="${ISDNNET_INCLUDE} "
  18473. if test "xmISDNuser/isdn_net.h" = "x" ; then # no header, assume found
  18474. ISDNNET_HEADER_FOUND="1"
  18475. else # check for the header
  18476. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18477. CPPFLAGS="${CPPFLAGS} ${ISDNNET_INCLUDE}"
  18478. ac_fn_c_check_header_mongrel "$LINENO" "mISDNuser/isdn_net.h" "ac_cv_header_mISDNuser_isdn_net_h" "$ac_includes_default"
  18479. if test "x$ac_cv_header_mISDNuser_isdn_net_h" = xyes; then :
  18480. ISDNNET_HEADER_FOUND=1
  18481. else
  18482. ISDNNET_HEADER_FOUND=0
  18483. fi
  18484. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18485. fi
  18486. if test "x${ISDNNET_HEADER_FOUND}" = "x0" ; then
  18487. ISDNNET_LIB=""
  18488. ISDNNET_INCLUDE=""
  18489. else
  18490. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18491. ISDNNET_LIB=""
  18492. fi
  18493. PBX_ISDNNET=1
  18494. cat >>confdefs.h <<_ACEOF
  18495. #define HAVE_ISDNNET 1
  18496. _ACEOF
  18497. fi
  18498. fi
  18499. fi
  18500. if test "x${PBX_SUPPSERV}" != "x1" -a "${USE_SUPPSERV}" != "no"; then
  18501. pbxlibdir=""
  18502. # if --with-SUPPSERV=DIR has been specified, use it.
  18503. if test "x${SUPPSERV_DIR}" != "x"; then
  18504. if test -d ${SUPPSERV_DIR}/lib; then
  18505. pbxlibdir="-L${SUPPSERV_DIR}/lib"
  18506. else
  18507. pbxlibdir="-L${SUPPSERV_DIR}"
  18508. fi
  18509. fi
  18510. pbxfuncname="encodeFac"
  18511. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18512. AST_SUPPSERV_FOUND=yes
  18513. else
  18514. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18515. CFLAGS="${CFLAGS} "
  18516. as_ac_Lib=`$as_echo "ac_cv_lib_suppserv_${pbxfuncname}" | $as_tr_sh`
  18517. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsuppserv" >&5
  18518. $as_echo_n "checking for ${pbxfuncname} in -lsuppserv... " >&6; }
  18519. if eval \${$as_ac_Lib+:} false; then :
  18520. $as_echo_n "(cached) " >&6
  18521. else
  18522. ac_check_lib_save_LIBS=$LIBS
  18523. LIBS="-lsuppserv ${pbxlibdir} $LIBS"
  18524. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18525. /* end confdefs.h. */
  18526. /* Override any GCC internal prototype to avoid an error.
  18527. Use char because int might match the return type of a GCC
  18528. builtin and then its argument prototype would still apply. */
  18529. #ifdef __cplusplus
  18530. extern "C"
  18531. #endif
  18532. char ${pbxfuncname} ();
  18533. int
  18534. main ()
  18535. {
  18536. return ${pbxfuncname} ();
  18537. ;
  18538. return 0;
  18539. }
  18540. _ACEOF
  18541. if ac_fn_c_try_link "$LINENO"; then :
  18542. eval "$as_ac_Lib=yes"
  18543. else
  18544. eval "$as_ac_Lib=no"
  18545. fi
  18546. rm -f core conftest.err conftest.$ac_objext \
  18547. conftest$ac_exeext conftest.$ac_ext
  18548. LIBS=$ac_check_lib_save_LIBS
  18549. fi
  18550. eval ac_res=\$$as_ac_Lib
  18551. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18552. $as_echo "$ac_res" >&6; }
  18553. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18554. AST_SUPPSERV_FOUND=yes
  18555. else
  18556. AST_SUPPSERV_FOUND=no
  18557. fi
  18558. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18559. fi
  18560. # now check for the header.
  18561. if test "${AST_SUPPSERV_FOUND}" = "yes"; then
  18562. SUPPSERV_LIB="${pbxlibdir} -lsuppserv "
  18563. # if --with-SUPPSERV=DIR has been specified, use it.
  18564. if test "x${SUPPSERV_DIR}" != "x"; then
  18565. SUPPSERV_INCLUDE="-I${SUPPSERV_DIR}/include"
  18566. fi
  18567. SUPPSERV_INCLUDE="${SUPPSERV_INCLUDE} "
  18568. if test "xmISDNuser/suppserv.h" = "x" ; then # no header, assume found
  18569. SUPPSERV_HEADER_FOUND="1"
  18570. else # check for the header
  18571. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18572. CPPFLAGS="${CPPFLAGS} ${SUPPSERV_INCLUDE}"
  18573. ac_fn_c_check_header_mongrel "$LINENO" "mISDNuser/suppserv.h" "ac_cv_header_mISDNuser_suppserv_h" "$ac_includes_default"
  18574. if test "x$ac_cv_header_mISDNuser_suppserv_h" = xyes; then :
  18575. SUPPSERV_HEADER_FOUND=1
  18576. else
  18577. SUPPSERV_HEADER_FOUND=0
  18578. fi
  18579. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18580. fi
  18581. if test "x${SUPPSERV_HEADER_FOUND}" = "x0" ; then
  18582. SUPPSERV_LIB=""
  18583. SUPPSERV_INCLUDE=""
  18584. else
  18585. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18586. SUPPSERV_LIB=""
  18587. fi
  18588. PBX_SUPPSERV=1
  18589. cat >>confdefs.h <<_ACEOF
  18590. #define HAVE_SUPPSERV 1
  18591. _ACEOF
  18592. fi
  18593. fi
  18594. fi
  18595. if test "x${PBX_MISDN_FAC_RESULT}" != "x1"; then
  18596. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Fac_RESULT in mISDNuser/suppserv.h" >&5
  18597. $as_echo_n "checking for Fac_RESULT in mISDNuser/suppserv.h... " >&6; }
  18598. saved_cppflags="${CPPFLAGS}"
  18599. if test "x${MISDN_FAC_RESULT_DIR}" != "x"; then
  18600. MISDN_FAC_RESULT_INCLUDE="-I${MISDN_FAC_RESULT_DIR}/include"
  18601. fi
  18602. CPPFLAGS="${CPPFLAGS} ${MISDN_FAC_RESULT_INCLUDE}"
  18603. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18604. /* end confdefs.h. */
  18605. #include <mISDNuser/suppserv.h>
  18606. int
  18607. main ()
  18608. {
  18609. #if defined(Fac_RESULT)
  18610. int foo = 0;
  18611. #else
  18612. int foo = bar;
  18613. #endif
  18614. 0
  18615. ;
  18616. return 0;
  18617. }
  18618. _ACEOF
  18619. if ac_fn_c_try_compile "$LINENO"; then :
  18620. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  18621. $as_echo "yes" >&6; }
  18622. PBX_MISDN_FAC_RESULT=1
  18623. $as_echo "#define HAVE_MISDN_FAC_RESULT 1" >>confdefs.h
  18624. else
  18625. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18626. $as_echo "no" >&6; }
  18627. fi
  18628. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  18629. CPPFLAGS="${saved_cppflags}"
  18630. fi
  18631. if test "x${PBX_MISDN_FAC_ERROR}" != "x1"; then
  18632. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Fac_ERROR in mISDNuser/suppserv.h" >&5
  18633. $as_echo_n "checking for Fac_ERROR in mISDNuser/suppserv.h... " >&6; }
  18634. saved_cppflags="${CPPFLAGS}"
  18635. if test "x${MISDN_FAC_ERROR_DIR}" != "x"; then
  18636. MISDN_FAC_ERROR_INCLUDE="-I${MISDN_FAC_ERROR_DIR}/include"
  18637. fi
  18638. CPPFLAGS="${CPPFLAGS} ${MISDN_FAC_ERROR_INCLUDE}"
  18639. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18640. /* end confdefs.h. */
  18641. #include <mISDNuser/suppserv.h>
  18642. int
  18643. main ()
  18644. {
  18645. #if defined(Fac_ERROR)
  18646. int foo = 0;
  18647. #else
  18648. int foo = bar;
  18649. #endif
  18650. 0
  18651. ;
  18652. return 0;
  18653. }
  18654. _ACEOF
  18655. if ac_fn_c_try_compile "$LINENO"; then :
  18656. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  18657. $as_echo "yes" >&6; }
  18658. PBX_MISDN_FAC_ERROR=1
  18659. $as_echo "#define HAVE_MISDN_FAC_ERROR 1" >>confdefs.h
  18660. else
  18661. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18662. $as_echo "no" >&6; }
  18663. fi
  18664. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  18665. CPPFLAGS="${saved_cppflags}"
  18666. fi
  18667. ac_fn_c_check_header_mongrel "$LINENO" "linux/mISDNdsp.h" "ac_cv_header_linux_mISDNdsp_h" "$ac_includes_default"
  18668. if test "x$ac_cv_header_linux_mISDNdsp_h" = xyes; then :
  18669. cat >>confdefs.h <<_ACEOF
  18670. #define MISDN_1_2 1
  18671. _ACEOF
  18672. fi
  18673. ac_fn_c_check_member "$LINENO" "Q931_info_t" "redirect_dn" "ac_cv_member_Q931_info_t_redirect_dn" "#include <mISDNuser/mISDNlib.h>
  18674. "
  18675. if test "x$ac_cv_member_Q931_info_t_redirect_dn" = xyes; then :
  18676. else
  18677. PBX_MISDN=0
  18678. fi
  18679. fi
  18680. if test "x${PBX_MYSQLCLIENT}" != "x1" -a "${USE_MYSQLCLIENT}" != "no"; then
  18681. PBX_MYSQLCLIENT=0
  18682. if test -n "$ac_tool_prefix"; then
  18683. # Extract the first word of "${ac_tool_prefix}mysql_config", so it can be a program name with args.
  18684. set dummy ${ac_tool_prefix}mysql_config; ac_word=$2
  18685. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18686. $as_echo_n "checking for $ac_word... " >&6; }
  18687. if ${ac_cv_path_CONFIG_MYSQLCLIENT+:} false; then :
  18688. $as_echo_n "(cached) " >&6
  18689. else
  18690. case $CONFIG_MYSQLCLIENT in
  18691. [\\/]* | ?:[\\/]*)
  18692. ac_cv_path_CONFIG_MYSQLCLIENT="$CONFIG_MYSQLCLIENT" # Let the user override the test with a path.
  18693. ;;
  18694. *)
  18695. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18696. as_dummy="${MYSQLCLIENT_DIR}/bin:$PATH"
  18697. for as_dir in $as_dummy
  18698. do
  18699. IFS=$as_save_IFS
  18700. test -z "$as_dir" && as_dir=.
  18701. for ac_exec_ext in '' $ac_executable_extensions; do
  18702. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18703. ac_cv_path_CONFIG_MYSQLCLIENT="$as_dir/$ac_word$ac_exec_ext"
  18704. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18705. break 2
  18706. fi
  18707. done
  18708. done
  18709. IFS=$as_save_IFS
  18710. ;;
  18711. esac
  18712. fi
  18713. CONFIG_MYSQLCLIENT=$ac_cv_path_CONFIG_MYSQLCLIENT
  18714. if test -n "$CONFIG_MYSQLCLIENT"; then
  18715. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_MYSQLCLIENT" >&5
  18716. $as_echo "$CONFIG_MYSQLCLIENT" >&6; }
  18717. else
  18718. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18719. $as_echo "no" >&6; }
  18720. fi
  18721. fi
  18722. if test -z "$ac_cv_path_CONFIG_MYSQLCLIENT"; then
  18723. ac_pt_CONFIG_MYSQLCLIENT=$CONFIG_MYSQLCLIENT
  18724. # Extract the first word of "mysql_config", so it can be a program name with args.
  18725. set dummy mysql_config; ac_word=$2
  18726. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18727. $as_echo_n "checking for $ac_word... " >&6; }
  18728. if ${ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT+:} false; then :
  18729. $as_echo_n "(cached) " >&6
  18730. else
  18731. case $ac_pt_CONFIG_MYSQLCLIENT in
  18732. [\\/]* | ?:[\\/]*)
  18733. ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT="$ac_pt_CONFIG_MYSQLCLIENT" # Let the user override the test with a path.
  18734. ;;
  18735. *)
  18736. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18737. as_dummy="${MYSQLCLIENT_DIR}/bin:$PATH"
  18738. for as_dir in $as_dummy
  18739. do
  18740. IFS=$as_save_IFS
  18741. test -z "$as_dir" && as_dir=.
  18742. for ac_exec_ext in '' $ac_executable_extensions; do
  18743. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18744. ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT="$as_dir/$ac_word$ac_exec_ext"
  18745. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18746. break 2
  18747. fi
  18748. done
  18749. done
  18750. IFS=$as_save_IFS
  18751. ;;
  18752. esac
  18753. fi
  18754. ac_pt_CONFIG_MYSQLCLIENT=$ac_cv_path_ac_pt_CONFIG_MYSQLCLIENT
  18755. if test -n "$ac_pt_CONFIG_MYSQLCLIENT"; then
  18756. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_MYSQLCLIENT" >&5
  18757. $as_echo "$ac_pt_CONFIG_MYSQLCLIENT" >&6; }
  18758. else
  18759. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18760. $as_echo "no" >&6; }
  18761. fi
  18762. if test "x$ac_pt_CONFIG_MYSQLCLIENT" = x; then
  18763. CONFIG_MYSQLCLIENT="No"
  18764. else
  18765. case $cross_compiling:$ac_tool_warned in
  18766. yes:)
  18767. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  18768. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  18769. ac_tool_warned=yes ;;
  18770. esac
  18771. CONFIG_MYSQLCLIENT=$ac_pt_CONFIG_MYSQLCLIENT
  18772. fi
  18773. else
  18774. CONFIG_MYSQLCLIENT="$ac_cv_path_CONFIG_MYSQLCLIENT"
  18775. fi
  18776. if test ! "x${CONFIG_MYSQLCLIENT}" = xNo; then
  18777. if test x"" = x ; then A=--cflags ; else A="" ; fi
  18778. MYSQLCLIENT_INCLUDE=$(${CONFIG_MYSQLCLIENT} $A)
  18779. MYSQLCLIENT_INCLUDE=$(echo ${MYSQLCLIENT_INCLUDE} | $SED -e "s|-I|-I${MYSQLCLIENT_DIR}|g")
  18780. if test x"" = x ; then A=--libs ; else A="" ; fi
  18781. MYSQLCLIENT_LIB=$(${CONFIG_MYSQLCLIENT} $A)
  18782. MYSQLCLIENT_LIB=$(echo ${MYSQLCLIENT_LIB} | $SED -e "s|-L|-L${MYSQLCLIENT_DIR}|g")
  18783. if test x"" != x ; then
  18784. saved_cppflags="${CPPFLAGS}"
  18785. CPPFLAGS="${CPPFLAGS} ${MYSQLCLIENT_INCLUDE}"
  18786. saved_libs="${LIBS}"
  18787. LIBS=${MYSQLCLIENT_LIB}
  18788. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18789. /* end confdefs.h. */
  18790. int
  18791. main ()
  18792. {
  18793. ;
  18794. ;
  18795. return 0;
  18796. }
  18797. _ACEOF
  18798. if ac_fn_c_try_link "$LINENO"; then :
  18799. PBX_MYSQLCLIENT=1
  18800. $as_echo "#define HAVE_MYSQLCLIENT 1" >>confdefs.h
  18801. fi
  18802. rm -f core conftest.err conftest.$ac_objext \
  18803. conftest$ac_exeext conftest.$ac_ext
  18804. CPPFLAGS="${saved_cppflags}"
  18805. LIBS="${saved_libs}"
  18806. else
  18807. PBX_MYSQLCLIENT=1
  18808. $as_echo "#define HAVE_MYSQLCLIENT 1" >>confdefs.h
  18809. fi
  18810. fi
  18811. fi
  18812. if test "x${PBX_NBS}" != "x1" -a "${USE_NBS}" != "no"; then
  18813. pbxlibdir=""
  18814. # if --with-NBS=DIR has been specified, use it.
  18815. if test "x${NBS_DIR}" != "x"; then
  18816. if test -d ${NBS_DIR}/lib; then
  18817. pbxlibdir="-L${NBS_DIR}/lib"
  18818. else
  18819. pbxlibdir="-L${NBS_DIR}"
  18820. fi
  18821. fi
  18822. pbxfuncname="nbs_connect"
  18823. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  18824. AST_NBS_FOUND=yes
  18825. else
  18826. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  18827. CFLAGS="${CFLAGS} "
  18828. as_ac_Lib=`$as_echo "ac_cv_lib_nbs_${pbxfuncname}" | $as_tr_sh`
  18829. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lnbs" >&5
  18830. $as_echo_n "checking for ${pbxfuncname} in -lnbs... " >&6; }
  18831. if eval \${$as_ac_Lib+:} false; then :
  18832. $as_echo_n "(cached) " >&6
  18833. else
  18834. ac_check_lib_save_LIBS=$LIBS
  18835. LIBS="-lnbs ${pbxlibdir} $LIBS"
  18836. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  18837. /* end confdefs.h. */
  18838. /* Override any GCC internal prototype to avoid an error.
  18839. Use char because int might match the return type of a GCC
  18840. builtin and then its argument prototype would still apply. */
  18841. #ifdef __cplusplus
  18842. extern "C"
  18843. #endif
  18844. char ${pbxfuncname} ();
  18845. int
  18846. main ()
  18847. {
  18848. return ${pbxfuncname} ();
  18849. ;
  18850. return 0;
  18851. }
  18852. _ACEOF
  18853. if ac_fn_c_try_link "$LINENO"; then :
  18854. eval "$as_ac_Lib=yes"
  18855. else
  18856. eval "$as_ac_Lib=no"
  18857. fi
  18858. rm -f core conftest.err conftest.$ac_objext \
  18859. conftest$ac_exeext conftest.$ac_ext
  18860. LIBS=$ac_check_lib_save_LIBS
  18861. fi
  18862. eval ac_res=\$$as_ac_Lib
  18863. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  18864. $as_echo "$ac_res" >&6; }
  18865. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  18866. AST_NBS_FOUND=yes
  18867. else
  18868. AST_NBS_FOUND=no
  18869. fi
  18870. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  18871. fi
  18872. # now check for the header.
  18873. if test "${AST_NBS_FOUND}" = "yes"; then
  18874. NBS_LIB="${pbxlibdir} -lnbs "
  18875. # if --with-NBS=DIR has been specified, use it.
  18876. if test "x${NBS_DIR}" != "x"; then
  18877. NBS_INCLUDE="-I${NBS_DIR}/include"
  18878. fi
  18879. NBS_INCLUDE="${NBS_INCLUDE} "
  18880. if test "xnbs.h" = "x" ; then # no header, assume found
  18881. NBS_HEADER_FOUND="1"
  18882. else # check for the header
  18883. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  18884. CPPFLAGS="${CPPFLAGS} ${NBS_INCLUDE}"
  18885. ac_fn_c_check_header_mongrel "$LINENO" "nbs.h" "ac_cv_header_nbs_h" "$ac_includes_default"
  18886. if test "x$ac_cv_header_nbs_h" = xyes; then :
  18887. NBS_HEADER_FOUND=1
  18888. else
  18889. NBS_HEADER_FOUND=0
  18890. fi
  18891. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  18892. fi
  18893. if test "x${NBS_HEADER_FOUND}" = "x0" ; then
  18894. NBS_LIB=""
  18895. NBS_INCLUDE=""
  18896. else
  18897. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  18898. NBS_LIB=""
  18899. fi
  18900. PBX_NBS=1
  18901. cat >>confdefs.h <<_ACEOF
  18902. #define HAVE_NBS 1
  18903. _ACEOF
  18904. fi
  18905. fi
  18906. fi
  18907. if test "x${PBX_NEON}" != "x1" -a "${USE_NEON}" != "no"; then
  18908. PBX_NEON=0
  18909. if test -n "$ac_tool_prefix"; then
  18910. # Extract the first word of "${ac_tool_prefix}neon-config", so it can be a program name with args.
  18911. set dummy ${ac_tool_prefix}neon-config; ac_word=$2
  18912. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18913. $as_echo_n "checking for $ac_word... " >&6; }
  18914. if ${ac_cv_path_CONFIG_NEON+:} false; then :
  18915. $as_echo_n "(cached) " >&6
  18916. else
  18917. case $CONFIG_NEON in
  18918. [\\/]* | ?:[\\/]*)
  18919. ac_cv_path_CONFIG_NEON="$CONFIG_NEON" # Let the user override the test with a path.
  18920. ;;
  18921. *)
  18922. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18923. as_dummy="${NEON_DIR}/bin:$PATH"
  18924. for as_dir in $as_dummy
  18925. do
  18926. IFS=$as_save_IFS
  18927. test -z "$as_dir" && as_dir=.
  18928. for ac_exec_ext in '' $ac_executable_extensions; do
  18929. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18930. ac_cv_path_CONFIG_NEON="$as_dir/$ac_word$ac_exec_ext"
  18931. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18932. break 2
  18933. fi
  18934. done
  18935. done
  18936. IFS=$as_save_IFS
  18937. ;;
  18938. esac
  18939. fi
  18940. CONFIG_NEON=$ac_cv_path_CONFIG_NEON
  18941. if test -n "$CONFIG_NEON"; then
  18942. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_NEON" >&5
  18943. $as_echo "$CONFIG_NEON" >&6; }
  18944. else
  18945. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18946. $as_echo "no" >&6; }
  18947. fi
  18948. fi
  18949. if test -z "$ac_cv_path_CONFIG_NEON"; then
  18950. ac_pt_CONFIG_NEON=$CONFIG_NEON
  18951. # Extract the first word of "neon-config", so it can be a program name with args.
  18952. set dummy neon-config; ac_word=$2
  18953. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  18954. $as_echo_n "checking for $ac_word... " >&6; }
  18955. if ${ac_cv_path_ac_pt_CONFIG_NEON+:} false; then :
  18956. $as_echo_n "(cached) " >&6
  18957. else
  18958. case $ac_pt_CONFIG_NEON in
  18959. [\\/]* | ?:[\\/]*)
  18960. ac_cv_path_ac_pt_CONFIG_NEON="$ac_pt_CONFIG_NEON" # Let the user override the test with a path.
  18961. ;;
  18962. *)
  18963. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  18964. as_dummy="${NEON_DIR}/bin:$PATH"
  18965. for as_dir in $as_dummy
  18966. do
  18967. IFS=$as_save_IFS
  18968. test -z "$as_dir" && as_dir=.
  18969. for ac_exec_ext in '' $ac_executable_extensions; do
  18970. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  18971. ac_cv_path_ac_pt_CONFIG_NEON="$as_dir/$ac_word$ac_exec_ext"
  18972. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  18973. break 2
  18974. fi
  18975. done
  18976. done
  18977. IFS=$as_save_IFS
  18978. ;;
  18979. esac
  18980. fi
  18981. ac_pt_CONFIG_NEON=$ac_cv_path_ac_pt_CONFIG_NEON
  18982. if test -n "$ac_pt_CONFIG_NEON"; then
  18983. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_NEON" >&5
  18984. $as_echo "$ac_pt_CONFIG_NEON" >&6; }
  18985. else
  18986. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  18987. $as_echo "no" >&6; }
  18988. fi
  18989. if test "x$ac_pt_CONFIG_NEON" = x; then
  18990. CONFIG_NEON="No"
  18991. else
  18992. case $cross_compiling:$ac_tool_warned in
  18993. yes:)
  18994. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  18995. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  18996. ac_tool_warned=yes ;;
  18997. esac
  18998. CONFIG_NEON=$ac_pt_CONFIG_NEON
  18999. fi
  19000. else
  19001. CONFIG_NEON="$ac_cv_path_CONFIG_NEON"
  19002. fi
  19003. if test ! "x${CONFIG_NEON}" = xNo; then
  19004. if test x"" = x ; then A=--cflags ; else A="" ; fi
  19005. NEON_INCLUDE=$(${CONFIG_NEON} $A)
  19006. NEON_INCLUDE=$(echo ${NEON_INCLUDE} | $SED -e "s|-I|-I${NEON_DIR}|g")
  19007. if test x"" = x ; then A=--libs ; else A="" ; fi
  19008. NEON_LIB=$(${CONFIG_NEON} $A)
  19009. NEON_LIB=$(echo ${NEON_LIB} | $SED -e "s|-L|-L${NEON_DIR}|g")
  19010. if test x"" != x ; then
  19011. saved_cppflags="${CPPFLAGS}"
  19012. CPPFLAGS="${CPPFLAGS} ${NEON_INCLUDE}"
  19013. saved_libs="${LIBS}"
  19014. LIBS=${NEON_LIB}
  19015. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19016. /* end confdefs.h. */
  19017. int
  19018. main ()
  19019. {
  19020. ;
  19021. ;
  19022. return 0;
  19023. }
  19024. _ACEOF
  19025. if ac_fn_c_try_link "$LINENO"; then :
  19026. PBX_NEON=1
  19027. $as_echo "#define HAVE_NEON 1" >>confdefs.h
  19028. fi
  19029. rm -f core conftest.err conftest.$ac_objext \
  19030. conftest$ac_exeext conftest.$ac_ext
  19031. CPPFLAGS="${saved_cppflags}"
  19032. LIBS="${saved_libs}"
  19033. else
  19034. PBX_NEON=1
  19035. $as_echo "#define HAVE_NEON 1" >>confdefs.h
  19036. fi
  19037. fi
  19038. fi
  19039. if test "x${PBX_NEON29}" != "x1" -a "${USE_NEON29}" != "no"; then
  19040. PBX_NEON29=0
  19041. if test -n "$ac_tool_prefix"; then
  19042. # Extract the first word of "${ac_tool_prefix}neon-config", so it can be a program name with args.
  19043. set dummy ${ac_tool_prefix}neon-config; ac_word=$2
  19044. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  19045. $as_echo_n "checking for $ac_word... " >&6; }
  19046. if ${ac_cv_path_CONFIG_NEON29+:} false; then :
  19047. $as_echo_n "(cached) " >&6
  19048. else
  19049. case $CONFIG_NEON29 in
  19050. [\\/]* | ?:[\\/]*)
  19051. ac_cv_path_CONFIG_NEON29="$CONFIG_NEON29" # Let the user override the test with a path.
  19052. ;;
  19053. *)
  19054. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  19055. as_dummy="${NEON29_DIR}/bin:$PATH"
  19056. for as_dir in $as_dummy
  19057. do
  19058. IFS=$as_save_IFS
  19059. test -z "$as_dir" && as_dir=.
  19060. for ac_exec_ext in '' $ac_executable_extensions; do
  19061. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  19062. ac_cv_path_CONFIG_NEON29="$as_dir/$ac_word$ac_exec_ext"
  19063. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  19064. break 2
  19065. fi
  19066. done
  19067. done
  19068. IFS=$as_save_IFS
  19069. ;;
  19070. esac
  19071. fi
  19072. CONFIG_NEON29=$ac_cv_path_CONFIG_NEON29
  19073. if test -n "$CONFIG_NEON29"; then
  19074. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_NEON29" >&5
  19075. $as_echo "$CONFIG_NEON29" >&6; }
  19076. else
  19077. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  19078. $as_echo "no" >&6; }
  19079. fi
  19080. fi
  19081. if test -z "$ac_cv_path_CONFIG_NEON29"; then
  19082. ac_pt_CONFIG_NEON29=$CONFIG_NEON29
  19083. # Extract the first word of "neon-config", so it can be a program name with args.
  19084. set dummy neon-config; ac_word=$2
  19085. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  19086. $as_echo_n "checking for $ac_word... " >&6; }
  19087. if ${ac_cv_path_ac_pt_CONFIG_NEON29+:} false; then :
  19088. $as_echo_n "(cached) " >&6
  19089. else
  19090. case $ac_pt_CONFIG_NEON29 in
  19091. [\\/]* | ?:[\\/]*)
  19092. ac_cv_path_ac_pt_CONFIG_NEON29="$ac_pt_CONFIG_NEON29" # Let the user override the test with a path.
  19093. ;;
  19094. *)
  19095. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  19096. as_dummy="${NEON29_DIR}/bin:$PATH"
  19097. for as_dir in $as_dummy
  19098. do
  19099. IFS=$as_save_IFS
  19100. test -z "$as_dir" && as_dir=.
  19101. for ac_exec_ext in '' $ac_executable_extensions; do
  19102. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  19103. ac_cv_path_ac_pt_CONFIG_NEON29="$as_dir/$ac_word$ac_exec_ext"
  19104. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  19105. break 2
  19106. fi
  19107. done
  19108. done
  19109. IFS=$as_save_IFS
  19110. ;;
  19111. esac
  19112. fi
  19113. ac_pt_CONFIG_NEON29=$ac_cv_path_ac_pt_CONFIG_NEON29
  19114. if test -n "$ac_pt_CONFIG_NEON29"; then
  19115. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_NEON29" >&5
  19116. $as_echo "$ac_pt_CONFIG_NEON29" >&6; }
  19117. else
  19118. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  19119. $as_echo "no" >&6; }
  19120. fi
  19121. if test "x$ac_pt_CONFIG_NEON29" = x; then
  19122. CONFIG_NEON29="No"
  19123. else
  19124. case $cross_compiling:$ac_tool_warned in
  19125. yes:)
  19126. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  19127. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  19128. ac_tool_warned=yes ;;
  19129. esac
  19130. CONFIG_NEON29=$ac_pt_CONFIG_NEON29
  19131. fi
  19132. else
  19133. CONFIG_NEON29="$ac_cv_path_CONFIG_NEON29"
  19134. fi
  19135. if test ! "x${CONFIG_NEON29}" = xNo; then
  19136. if test x"" = x ; then A=--cflags ; else A="" ; fi
  19137. NEON29_INCLUDE=$(${CONFIG_NEON29} $A)
  19138. NEON29_INCLUDE=$(echo ${NEON29_INCLUDE} | $SED -e "s|-I|-I${NEON29_DIR}|g")
  19139. if test x"--libs" = x ; then A=--libs ; else A="--libs" ; fi
  19140. NEON29_LIB=$(${CONFIG_NEON29} $A)
  19141. NEON29_LIB=$(echo ${NEON29_LIB} | $SED -e "s|-L|-L${NEON29_DIR}|g")
  19142. if test x"#include <ne_auth.h>" != x ; then
  19143. saved_cppflags="${CPPFLAGS}"
  19144. CPPFLAGS="${CPPFLAGS} ${NEON29_INCLUDE}"
  19145. saved_libs="${LIBS}"
  19146. LIBS=${NEON29_LIB}
  19147. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19148. /* end confdefs.h. */
  19149. #include <ne_auth.h>
  19150. int
  19151. main ()
  19152. {
  19153. #ifndef NE_AUTH_NTLM
  19154. #error Need libneon >= 0.29.0
  19155. #endif;
  19156. ;
  19157. return 0;
  19158. }
  19159. _ACEOF
  19160. if ac_fn_c_try_link "$LINENO"; then :
  19161. PBX_NEON29=1
  19162. $as_echo "#define HAVE_NEON29 1" >>confdefs.h
  19163. fi
  19164. rm -f core conftest.err conftest.$ac_objext \
  19165. conftest$ac_exeext conftest.$ac_ext
  19166. CPPFLAGS="${saved_cppflags}"
  19167. LIBS="${saved_libs}"
  19168. else
  19169. PBX_NEON29=1
  19170. $as_echo "#define HAVE_NEON29 1" >>confdefs.h
  19171. fi
  19172. fi
  19173. fi
  19174. if test "x${PBX_NETSNMP}" != "x1" -a "${USE_NETSNMP}" != "no"; then
  19175. PBX_NETSNMP=0
  19176. if test -n "$ac_tool_prefix"; then
  19177. # Extract the first word of "${ac_tool_prefix}net-snmp-config", so it can be a program name with args.
  19178. set dummy ${ac_tool_prefix}net-snmp-config; ac_word=$2
  19179. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  19180. $as_echo_n "checking for $ac_word... " >&6; }
  19181. if ${ac_cv_path_CONFIG_NETSNMP+:} false; then :
  19182. $as_echo_n "(cached) " >&6
  19183. else
  19184. case $CONFIG_NETSNMP in
  19185. [\\/]* | ?:[\\/]*)
  19186. ac_cv_path_CONFIG_NETSNMP="$CONFIG_NETSNMP" # Let the user override the test with a path.
  19187. ;;
  19188. *)
  19189. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  19190. as_dummy="${NETSNMP_DIR}/bin:$PATH"
  19191. for as_dir in $as_dummy
  19192. do
  19193. IFS=$as_save_IFS
  19194. test -z "$as_dir" && as_dir=.
  19195. for ac_exec_ext in '' $ac_executable_extensions; do
  19196. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  19197. ac_cv_path_CONFIG_NETSNMP="$as_dir/$ac_word$ac_exec_ext"
  19198. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  19199. break 2
  19200. fi
  19201. done
  19202. done
  19203. IFS=$as_save_IFS
  19204. ;;
  19205. esac
  19206. fi
  19207. CONFIG_NETSNMP=$ac_cv_path_CONFIG_NETSNMP
  19208. if test -n "$CONFIG_NETSNMP"; then
  19209. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_NETSNMP" >&5
  19210. $as_echo "$CONFIG_NETSNMP" >&6; }
  19211. else
  19212. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  19213. $as_echo "no" >&6; }
  19214. fi
  19215. fi
  19216. if test -z "$ac_cv_path_CONFIG_NETSNMP"; then
  19217. ac_pt_CONFIG_NETSNMP=$CONFIG_NETSNMP
  19218. # Extract the first word of "net-snmp-config", so it can be a program name with args.
  19219. set dummy net-snmp-config; ac_word=$2
  19220. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  19221. $as_echo_n "checking for $ac_word... " >&6; }
  19222. if ${ac_cv_path_ac_pt_CONFIG_NETSNMP+:} false; then :
  19223. $as_echo_n "(cached) " >&6
  19224. else
  19225. case $ac_pt_CONFIG_NETSNMP in
  19226. [\\/]* | ?:[\\/]*)
  19227. ac_cv_path_ac_pt_CONFIG_NETSNMP="$ac_pt_CONFIG_NETSNMP" # Let the user override the test with a path.
  19228. ;;
  19229. *)
  19230. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  19231. as_dummy="${NETSNMP_DIR}/bin:$PATH"
  19232. for as_dir in $as_dummy
  19233. do
  19234. IFS=$as_save_IFS
  19235. test -z "$as_dir" && as_dir=.
  19236. for ac_exec_ext in '' $ac_executable_extensions; do
  19237. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  19238. ac_cv_path_ac_pt_CONFIG_NETSNMP="$as_dir/$ac_word$ac_exec_ext"
  19239. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  19240. break 2
  19241. fi
  19242. done
  19243. done
  19244. IFS=$as_save_IFS
  19245. ;;
  19246. esac
  19247. fi
  19248. ac_pt_CONFIG_NETSNMP=$ac_cv_path_ac_pt_CONFIG_NETSNMP
  19249. if test -n "$ac_pt_CONFIG_NETSNMP"; then
  19250. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_NETSNMP" >&5
  19251. $as_echo "$ac_pt_CONFIG_NETSNMP" >&6; }
  19252. else
  19253. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  19254. $as_echo "no" >&6; }
  19255. fi
  19256. if test "x$ac_pt_CONFIG_NETSNMP" = x; then
  19257. CONFIG_NETSNMP="No"
  19258. else
  19259. case $cross_compiling:$ac_tool_warned in
  19260. yes:)
  19261. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  19262. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  19263. ac_tool_warned=yes ;;
  19264. esac
  19265. CONFIG_NETSNMP=$ac_pt_CONFIG_NETSNMP
  19266. fi
  19267. else
  19268. CONFIG_NETSNMP="$ac_cv_path_CONFIG_NETSNMP"
  19269. fi
  19270. if test ! "x${CONFIG_NETSNMP}" = xNo; then
  19271. if test x"" = x ; then A=--cflags ; else A="" ; fi
  19272. NETSNMP_INCLUDE=$(${CONFIG_NETSNMP} $A)
  19273. NETSNMP_INCLUDE=$(echo ${NETSNMP_INCLUDE} | $SED -e "s|-I|-I${NETSNMP_DIR}|g")
  19274. if test x"--agent-libs" = x ; then A=--libs ; else A="--agent-libs" ; fi
  19275. NETSNMP_LIB=$(${CONFIG_NETSNMP} $A)
  19276. NETSNMP_LIB=$(echo ${NETSNMP_LIB} | $SED -e "s|-L|-L${NETSNMP_DIR}|g")
  19277. if test x"#include <net-snmp/net-snmp-config.h>
  19278. #include <net-snmp/net-snmp-includes.h>
  19279. #include <net-snmp/agent/net-snmp-agent-includes.h>" != x ; then
  19280. saved_cppflags="${CPPFLAGS}"
  19281. CPPFLAGS="${CPPFLAGS} ${NETSNMP_INCLUDE}"
  19282. saved_libs="${LIBS}"
  19283. LIBS=${NETSNMP_LIB}
  19284. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19285. /* end confdefs.h. */
  19286. #include <net-snmp/net-snmp-config.h>
  19287. #include <net-snmp/net-snmp-includes.h>
  19288. #include <net-snmp/agent/net-snmp-agent-includes.h>
  19289. int
  19290. main ()
  19291. {
  19292. int callback = snmp_register_callback(0, 0, NULL, NULL);
  19293. ;
  19294. return 0;
  19295. }
  19296. _ACEOF
  19297. if ac_fn_c_try_link "$LINENO"; then :
  19298. PBX_NETSNMP=1
  19299. $as_echo "#define HAVE_NETSNMP 1" >>confdefs.h
  19300. fi
  19301. rm -f core conftest.err conftest.$ac_objext \
  19302. conftest$ac_exeext conftest.$ac_ext
  19303. CPPFLAGS="${saved_cppflags}"
  19304. LIBS="${saved_libs}"
  19305. else
  19306. PBX_NETSNMP=1
  19307. $as_echo "#define HAVE_NETSNMP 1" >>confdefs.h
  19308. fi
  19309. fi
  19310. fi
  19311. if test "x${PBX_NEWT}" != "x1" -a "${USE_NEWT}" != "no"; then
  19312. pbxlibdir=""
  19313. # if --with-NEWT=DIR has been specified, use it.
  19314. if test "x${NEWT_DIR}" != "x"; then
  19315. if test -d ${NEWT_DIR}/lib; then
  19316. pbxlibdir="-L${NEWT_DIR}/lib"
  19317. else
  19318. pbxlibdir="-L${NEWT_DIR}"
  19319. fi
  19320. fi
  19321. pbxfuncname="newtBell"
  19322. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19323. AST_NEWT_FOUND=yes
  19324. else
  19325. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19326. CFLAGS="${CFLAGS} "
  19327. as_ac_Lib=`$as_echo "ac_cv_lib_newt_${pbxfuncname}" | $as_tr_sh`
  19328. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lnewt" >&5
  19329. $as_echo_n "checking for ${pbxfuncname} in -lnewt... " >&6; }
  19330. if eval \${$as_ac_Lib+:} false; then :
  19331. $as_echo_n "(cached) " >&6
  19332. else
  19333. ac_check_lib_save_LIBS=$LIBS
  19334. LIBS="-lnewt ${pbxlibdir} $LIBS"
  19335. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19336. /* end confdefs.h. */
  19337. /* Override any GCC internal prototype to avoid an error.
  19338. Use char because int might match the return type of a GCC
  19339. builtin and then its argument prototype would still apply. */
  19340. #ifdef __cplusplus
  19341. extern "C"
  19342. #endif
  19343. char ${pbxfuncname} ();
  19344. int
  19345. main ()
  19346. {
  19347. return ${pbxfuncname} ();
  19348. ;
  19349. return 0;
  19350. }
  19351. _ACEOF
  19352. if ac_fn_c_try_link "$LINENO"; then :
  19353. eval "$as_ac_Lib=yes"
  19354. else
  19355. eval "$as_ac_Lib=no"
  19356. fi
  19357. rm -f core conftest.err conftest.$ac_objext \
  19358. conftest$ac_exeext conftest.$ac_ext
  19359. LIBS=$ac_check_lib_save_LIBS
  19360. fi
  19361. eval ac_res=\$$as_ac_Lib
  19362. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19363. $as_echo "$ac_res" >&6; }
  19364. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19365. AST_NEWT_FOUND=yes
  19366. else
  19367. AST_NEWT_FOUND=no
  19368. fi
  19369. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19370. fi
  19371. # now check for the header.
  19372. if test "${AST_NEWT_FOUND}" = "yes"; then
  19373. NEWT_LIB="${pbxlibdir} -lnewt "
  19374. # if --with-NEWT=DIR has been specified, use it.
  19375. if test "x${NEWT_DIR}" != "x"; then
  19376. NEWT_INCLUDE="-I${NEWT_DIR}/include"
  19377. fi
  19378. NEWT_INCLUDE="${NEWT_INCLUDE} "
  19379. if test "xnewt.h" = "x" ; then # no header, assume found
  19380. NEWT_HEADER_FOUND="1"
  19381. else # check for the header
  19382. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19383. CPPFLAGS="${CPPFLAGS} ${NEWT_INCLUDE}"
  19384. ac_fn_c_check_header_mongrel "$LINENO" "newt.h" "ac_cv_header_newt_h" "$ac_includes_default"
  19385. if test "x$ac_cv_header_newt_h" = xyes; then :
  19386. NEWT_HEADER_FOUND=1
  19387. else
  19388. NEWT_HEADER_FOUND=0
  19389. fi
  19390. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19391. fi
  19392. if test "x${NEWT_HEADER_FOUND}" = "x0" ; then
  19393. NEWT_LIB=""
  19394. NEWT_INCLUDE=""
  19395. else
  19396. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19397. NEWT_LIB=""
  19398. fi
  19399. PBX_NEWT=1
  19400. cat >>confdefs.h <<_ACEOF
  19401. #define HAVE_NEWT 1
  19402. _ACEOF
  19403. fi
  19404. fi
  19405. fi
  19406. if test "x${PBX_UNBOUND}" != "x1" -a "${USE_UNBOUND}" != "no"; then
  19407. pbxlibdir=""
  19408. # if --with-UNBOUND=DIR has been specified, use it.
  19409. if test "x${UNBOUND_DIR}" != "x"; then
  19410. if test -d ${UNBOUND_DIR}/lib; then
  19411. pbxlibdir="-L${UNBOUND_DIR}/lib"
  19412. else
  19413. pbxlibdir="-L${UNBOUND_DIR}"
  19414. fi
  19415. fi
  19416. pbxfuncname="ub_ctx_create"
  19417. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19418. AST_UNBOUND_FOUND=yes
  19419. else
  19420. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19421. CFLAGS="${CFLAGS} "
  19422. as_ac_Lib=`$as_echo "ac_cv_lib_unbound_${pbxfuncname}" | $as_tr_sh`
  19423. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lunbound" >&5
  19424. $as_echo_n "checking for ${pbxfuncname} in -lunbound... " >&6; }
  19425. if eval \${$as_ac_Lib+:} false; then :
  19426. $as_echo_n "(cached) " >&6
  19427. else
  19428. ac_check_lib_save_LIBS=$LIBS
  19429. LIBS="-lunbound ${pbxlibdir} $LIBS"
  19430. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19431. /* end confdefs.h. */
  19432. /* Override any GCC internal prototype to avoid an error.
  19433. Use char because int might match the return type of a GCC
  19434. builtin and then its argument prototype would still apply. */
  19435. #ifdef __cplusplus
  19436. extern "C"
  19437. #endif
  19438. char ${pbxfuncname} ();
  19439. int
  19440. main ()
  19441. {
  19442. return ${pbxfuncname} ();
  19443. ;
  19444. return 0;
  19445. }
  19446. _ACEOF
  19447. if ac_fn_c_try_link "$LINENO"; then :
  19448. eval "$as_ac_Lib=yes"
  19449. else
  19450. eval "$as_ac_Lib=no"
  19451. fi
  19452. rm -f core conftest.err conftest.$ac_objext \
  19453. conftest$ac_exeext conftest.$ac_ext
  19454. LIBS=$ac_check_lib_save_LIBS
  19455. fi
  19456. eval ac_res=\$$as_ac_Lib
  19457. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19458. $as_echo "$ac_res" >&6; }
  19459. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19460. AST_UNBOUND_FOUND=yes
  19461. else
  19462. AST_UNBOUND_FOUND=no
  19463. fi
  19464. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19465. fi
  19466. # now check for the header.
  19467. if test "${AST_UNBOUND_FOUND}" = "yes"; then
  19468. UNBOUND_LIB="${pbxlibdir} -lunbound "
  19469. # if --with-UNBOUND=DIR has been specified, use it.
  19470. if test "x${UNBOUND_DIR}" != "x"; then
  19471. UNBOUND_INCLUDE="-I${UNBOUND_DIR}/include"
  19472. fi
  19473. UNBOUND_INCLUDE="${UNBOUND_INCLUDE} "
  19474. if test "xunbound.h" = "x" ; then # no header, assume found
  19475. UNBOUND_HEADER_FOUND="1"
  19476. else # check for the header
  19477. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19478. CPPFLAGS="${CPPFLAGS} ${UNBOUND_INCLUDE}"
  19479. ac_fn_c_check_header_mongrel "$LINENO" "unbound.h" "ac_cv_header_unbound_h" "$ac_includes_default"
  19480. if test "x$ac_cv_header_unbound_h" = xyes; then :
  19481. UNBOUND_HEADER_FOUND=1
  19482. else
  19483. UNBOUND_HEADER_FOUND=0
  19484. fi
  19485. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19486. fi
  19487. if test "x${UNBOUND_HEADER_FOUND}" = "x0" ; then
  19488. UNBOUND_LIB=""
  19489. UNBOUND_INCLUDE=""
  19490. else
  19491. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19492. UNBOUND_LIB=""
  19493. fi
  19494. PBX_UNBOUND=1
  19495. cat >>confdefs.h <<_ACEOF
  19496. #define HAVE_UNBOUND 1
  19497. _ACEOF
  19498. fi
  19499. fi
  19500. fi
  19501. if test "x${PBX_UNIXODBC}" != "x1" -a "${USE_UNIXODBC}" != "no"; then
  19502. pbxlibdir=""
  19503. # if --with-UNIXODBC=DIR has been specified, use it.
  19504. if test "x${UNIXODBC_DIR}" != "x"; then
  19505. if test -d ${UNIXODBC_DIR}/lib; then
  19506. pbxlibdir="-L${UNIXODBC_DIR}/lib"
  19507. else
  19508. pbxlibdir="-L${UNIXODBC_DIR}"
  19509. fi
  19510. fi
  19511. pbxfuncname="SQLConnect"
  19512. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19513. AST_UNIXODBC_FOUND=yes
  19514. else
  19515. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19516. CFLAGS="${CFLAGS} "
  19517. as_ac_Lib=`$as_echo "ac_cv_lib_odbc_${pbxfuncname}" | $as_tr_sh`
  19518. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lodbc" >&5
  19519. $as_echo_n "checking for ${pbxfuncname} in -lodbc... " >&6; }
  19520. if eval \${$as_ac_Lib+:} false; then :
  19521. $as_echo_n "(cached) " >&6
  19522. else
  19523. ac_check_lib_save_LIBS=$LIBS
  19524. LIBS="-lodbc ${pbxlibdir} $LIBS"
  19525. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19526. /* end confdefs.h. */
  19527. /* Override any GCC internal prototype to avoid an error.
  19528. Use char because int might match the return type of a GCC
  19529. builtin and then its argument prototype would still apply. */
  19530. #ifdef __cplusplus
  19531. extern "C"
  19532. #endif
  19533. char ${pbxfuncname} ();
  19534. int
  19535. main ()
  19536. {
  19537. return ${pbxfuncname} ();
  19538. ;
  19539. return 0;
  19540. }
  19541. _ACEOF
  19542. if ac_fn_c_try_link "$LINENO"; then :
  19543. eval "$as_ac_Lib=yes"
  19544. else
  19545. eval "$as_ac_Lib=no"
  19546. fi
  19547. rm -f core conftest.err conftest.$ac_objext \
  19548. conftest$ac_exeext conftest.$ac_ext
  19549. LIBS=$ac_check_lib_save_LIBS
  19550. fi
  19551. eval ac_res=\$$as_ac_Lib
  19552. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19553. $as_echo "$ac_res" >&6; }
  19554. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19555. AST_UNIXODBC_FOUND=yes
  19556. else
  19557. AST_UNIXODBC_FOUND=no
  19558. fi
  19559. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19560. fi
  19561. # now check for the header.
  19562. if test "${AST_UNIXODBC_FOUND}" = "yes"; then
  19563. UNIXODBC_LIB="${pbxlibdir} -lodbc "
  19564. # if --with-UNIXODBC=DIR has been specified, use it.
  19565. if test "x${UNIXODBC_DIR}" != "x"; then
  19566. UNIXODBC_INCLUDE="-I${UNIXODBC_DIR}/include"
  19567. fi
  19568. UNIXODBC_INCLUDE="${UNIXODBC_INCLUDE} "
  19569. if test "xsql.h" = "x" ; then # no header, assume found
  19570. UNIXODBC_HEADER_FOUND="1"
  19571. else # check for the header
  19572. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19573. CPPFLAGS="${CPPFLAGS} ${UNIXODBC_INCLUDE}"
  19574. ac_fn_c_check_header_mongrel "$LINENO" "sql.h" "ac_cv_header_sql_h" "$ac_includes_default"
  19575. if test "x$ac_cv_header_sql_h" = xyes; then :
  19576. UNIXODBC_HEADER_FOUND=1
  19577. else
  19578. UNIXODBC_HEADER_FOUND=0
  19579. fi
  19580. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19581. fi
  19582. if test "x${UNIXODBC_HEADER_FOUND}" = "x0" ; then
  19583. UNIXODBC_LIB=""
  19584. UNIXODBC_INCLUDE=""
  19585. else
  19586. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19587. UNIXODBC_LIB=""
  19588. fi
  19589. PBX_UNIXODBC=1
  19590. cat >>confdefs.h <<_ACEOF
  19591. #define HAVE_UNIXODBC 1
  19592. _ACEOF
  19593. fi
  19594. fi
  19595. fi
  19596. if test "x${PBX_OGG}" != "x1" -a "${USE_OGG}" != "no"; then
  19597. pbxlibdir=""
  19598. # if --with-OGG=DIR has been specified, use it.
  19599. if test "x${OGG_DIR}" != "x"; then
  19600. if test -d ${OGG_DIR}/lib; then
  19601. pbxlibdir="-L${OGG_DIR}/lib"
  19602. else
  19603. pbxlibdir="-L${OGG_DIR}"
  19604. fi
  19605. fi
  19606. pbxfuncname="ogg_sync_init"
  19607. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19608. AST_OGG_FOUND=yes
  19609. else
  19610. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19611. CFLAGS="${CFLAGS} "
  19612. as_ac_Lib=`$as_echo "ac_cv_lib_ogg_${pbxfuncname}" | $as_tr_sh`
  19613. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -logg" >&5
  19614. $as_echo_n "checking for ${pbxfuncname} in -logg... " >&6; }
  19615. if eval \${$as_ac_Lib+:} false; then :
  19616. $as_echo_n "(cached) " >&6
  19617. else
  19618. ac_check_lib_save_LIBS=$LIBS
  19619. LIBS="-logg ${pbxlibdir} $LIBS"
  19620. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19621. /* end confdefs.h. */
  19622. /* Override any GCC internal prototype to avoid an error.
  19623. Use char because int might match the return type of a GCC
  19624. builtin and then its argument prototype would still apply. */
  19625. #ifdef __cplusplus
  19626. extern "C"
  19627. #endif
  19628. char ${pbxfuncname} ();
  19629. int
  19630. main ()
  19631. {
  19632. return ${pbxfuncname} ();
  19633. ;
  19634. return 0;
  19635. }
  19636. _ACEOF
  19637. if ac_fn_c_try_link "$LINENO"; then :
  19638. eval "$as_ac_Lib=yes"
  19639. else
  19640. eval "$as_ac_Lib=no"
  19641. fi
  19642. rm -f core conftest.err conftest.$ac_objext \
  19643. conftest$ac_exeext conftest.$ac_ext
  19644. LIBS=$ac_check_lib_save_LIBS
  19645. fi
  19646. eval ac_res=\$$as_ac_Lib
  19647. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19648. $as_echo "$ac_res" >&6; }
  19649. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19650. AST_OGG_FOUND=yes
  19651. else
  19652. AST_OGG_FOUND=no
  19653. fi
  19654. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19655. fi
  19656. # now check for the header.
  19657. if test "${AST_OGG_FOUND}" = "yes"; then
  19658. OGG_LIB="${pbxlibdir} -logg "
  19659. # if --with-OGG=DIR has been specified, use it.
  19660. if test "x${OGG_DIR}" != "x"; then
  19661. OGG_INCLUDE="-I${OGG_DIR}/include"
  19662. fi
  19663. OGG_INCLUDE="${OGG_INCLUDE} "
  19664. if test "x" = "x" ; then # no header, assume found
  19665. OGG_HEADER_FOUND="1"
  19666. else # check for the header
  19667. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19668. CPPFLAGS="${CPPFLAGS} ${OGG_INCLUDE}"
  19669. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  19670. if test "x$ac_cv_header_" = xyes; then :
  19671. OGG_HEADER_FOUND=1
  19672. else
  19673. OGG_HEADER_FOUND=0
  19674. fi
  19675. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19676. fi
  19677. if test "x${OGG_HEADER_FOUND}" = "x0" ; then
  19678. OGG_LIB=""
  19679. OGG_INCLUDE=""
  19680. else
  19681. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19682. OGG_LIB=""
  19683. fi
  19684. PBX_OGG=1
  19685. cat >>confdefs.h <<_ACEOF
  19686. #define HAVE_OGG 1
  19687. _ACEOF
  19688. fi
  19689. fi
  19690. fi
  19691. # Non-glibc platforms require libexecinfo for backtrace support
  19692. if test "x${PBX_BKTR}" != "x1" -a "${USE_BKTR}" != "no"; then
  19693. pbxlibdir=""
  19694. # if --with-BKTR=DIR has been specified, use it.
  19695. if test "x${BKTR_DIR}" != "x"; then
  19696. if test -d ${BKTR_DIR}/lib; then
  19697. pbxlibdir="-L${BKTR_DIR}/lib"
  19698. else
  19699. pbxlibdir="-L${BKTR_DIR}"
  19700. fi
  19701. fi
  19702. pbxfuncname="backtrace"
  19703. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19704. AST_BKTR_FOUND=yes
  19705. else
  19706. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19707. CFLAGS="${CFLAGS} "
  19708. as_ac_Lib=`$as_echo "ac_cv_lib_execinfo_${pbxfuncname}" | $as_tr_sh`
  19709. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lexecinfo" >&5
  19710. $as_echo_n "checking for ${pbxfuncname} in -lexecinfo... " >&6; }
  19711. if eval \${$as_ac_Lib+:} false; then :
  19712. $as_echo_n "(cached) " >&6
  19713. else
  19714. ac_check_lib_save_LIBS=$LIBS
  19715. LIBS="-lexecinfo ${pbxlibdir} $LIBS"
  19716. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19717. /* end confdefs.h. */
  19718. /* Override any GCC internal prototype to avoid an error.
  19719. Use char because int might match the return type of a GCC
  19720. builtin and then its argument prototype would still apply. */
  19721. #ifdef __cplusplus
  19722. extern "C"
  19723. #endif
  19724. char ${pbxfuncname} ();
  19725. int
  19726. main ()
  19727. {
  19728. return ${pbxfuncname} ();
  19729. ;
  19730. return 0;
  19731. }
  19732. _ACEOF
  19733. if ac_fn_c_try_link "$LINENO"; then :
  19734. eval "$as_ac_Lib=yes"
  19735. else
  19736. eval "$as_ac_Lib=no"
  19737. fi
  19738. rm -f core conftest.err conftest.$ac_objext \
  19739. conftest$ac_exeext conftest.$ac_ext
  19740. LIBS=$ac_check_lib_save_LIBS
  19741. fi
  19742. eval ac_res=\$$as_ac_Lib
  19743. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19744. $as_echo "$ac_res" >&6; }
  19745. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19746. AST_BKTR_FOUND=yes
  19747. else
  19748. AST_BKTR_FOUND=no
  19749. fi
  19750. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19751. fi
  19752. # now check for the header.
  19753. if test "${AST_BKTR_FOUND}" = "yes"; then
  19754. BKTR_LIB="${pbxlibdir} -lexecinfo "
  19755. # if --with-BKTR=DIR has been specified, use it.
  19756. if test "x${BKTR_DIR}" != "x"; then
  19757. BKTR_INCLUDE="-I${BKTR_DIR}/include"
  19758. fi
  19759. BKTR_INCLUDE="${BKTR_INCLUDE} "
  19760. if test "xexecinfo.h" = "x" ; then # no header, assume found
  19761. BKTR_HEADER_FOUND="1"
  19762. else # check for the header
  19763. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19764. CPPFLAGS="${CPPFLAGS} ${BKTR_INCLUDE}"
  19765. ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
  19766. if test "x$ac_cv_header_execinfo_h" = xyes; then :
  19767. BKTR_HEADER_FOUND=1
  19768. else
  19769. BKTR_HEADER_FOUND=0
  19770. fi
  19771. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19772. fi
  19773. if test "x${BKTR_HEADER_FOUND}" = "x0" ; then
  19774. BKTR_LIB=""
  19775. BKTR_INCLUDE=""
  19776. else
  19777. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19778. BKTR_LIB=""
  19779. fi
  19780. PBX_BKTR=1
  19781. cat >>confdefs.h <<_ACEOF
  19782. #define HAVE_BKTR 1
  19783. _ACEOF
  19784. fi
  19785. fi
  19786. fi
  19787. # Linux, however, has backtrace directly in glibc
  19788. if test "x${PBX_BKTR}" != "x1" -a "${USE_BKTR}" != "no"; then
  19789. pbxlibdir=""
  19790. # if --with-BKTR=DIR has been specified, use it.
  19791. if test "x${BKTR_DIR}" != "x"; then
  19792. if test -d ${BKTR_DIR}/lib; then
  19793. pbxlibdir="-L${BKTR_DIR}/lib"
  19794. else
  19795. pbxlibdir="-L${BKTR_DIR}"
  19796. fi
  19797. fi
  19798. pbxfuncname="backtrace"
  19799. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19800. AST_BKTR_FOUND=yes
  19801. else
  19802. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19803. CFLAGS="${CFLAGS} "
  19804. as_ac_Lib=`$as_echo "ac_cv_lib_c_${pbxfuncname}" | $as_tr_sh`
  19805. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lc" >&5
  19806. $as_echo_n "checking for ${pbxfuncname} in -lc... " >&6; }
  19807. if eval \${$as_ac_Lib+:} false; then :
  19808. $as_echo_n "(cached) " >&6
  19809. else
  19810. ac_check_lib_save_LIBS=$LIBS
  19811. LIBS="-lc ${pbxlibdir} $LIBS"
  19812. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19813. /* end confdefs.h. */
  19814. /* Override any GCC internal prototype to avoid an error.
  19815. Use char because int might match the return type of a GCC
  19816. builtin and then its argument prototype would still apply. */
  19817. #ifdef __cplusplus
  19818. extern "C"
  19819. #endif
  19820. char ${pbxfuncname} ();
  19821. int
  19822. main ()
  19823. {
  19824. return ${pbxfuncname} ();
  19825. ;
  19826. return 0;
  19827. }
  19828. _ACEOF
  19829. if ac_fn_c_try_link "$LINENO"; then :
  19830. eval "$as_ac_Lib=yes"
  19831. else
  19832. eval "$as_ac_Lib=no"
  19833. fi
  19834. rm -f core conftest.err conftest.$ac_objext \
  19835. conftest$ac_exeext conftest.$ac_ext
  19836. LIBS=$ac_check_lib_save_LIBS
  19837. fi
  19838. eval ac_res=\$$as_ac_Lib
  19839. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19840. $as_echo "$ac_res" >&6; }
  19841. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19842. AST_BKTR_FOUND=yes
  19843. else
  19844. AST_BKTR_FOUND=no
  19845. fi
  19846. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19847. fi
  19848. # now check for the header.
  19849. if test "${AST_BKTR_FOUND}" = "yes"; then
  19850. BKTR_LIB="${pbxlibdir} -lc "
  19851. # if --with-BKTR=DIR has been specified, use it.
  19852. if test "x${BKTR_DIR}" != "x"; then
  19853. BKTR_INCLUDE="-I${BKTR_DIR}/include"
  19854. fi
  19855. BKTR_INCLUDE="${BKTR_INCLUDE} "
  19856. if test "xexecinfo.h" = "x" ; then # no header, assume found
  19857. BKTR_HEADER_FOUND="1"
  19858. else # check for the header
  19859. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19860. CPPFLAGS="${CPPFLAGS} ${BKTR_INCLUDE}"
  19861. ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
  19862. if test "x$ac_cv_header_execinfo_h" = xyes; then :
  19863. BKTR_HEADER_FOUND=1
  19864. else
  19865. BKTR_HEADER_FOUND=0
  19866. fi
  19867. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19868. fi
  19869. if test "x${BKTR_HEADER_FOUND}" = "x0" ; then
  19870. BKTR_LIB=""
  19871. BKTR_INCLUDE=""
  19872. else
  19873. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19874. BKTR_LIB=""
  19875. fi
  19876. PBX_BKTR=1
  19877. cat >>confdefs.h <<_ACEOF
  19878. #define HAVE_BKTR 1
  19879. _ACEOF
  19880. fi
  19881. fi
  19882. fi
  19883. if test "x${PBX_BLUETOOTH}" != "x1" -a "${USE_BLUETOOTH}" != "no"; then
  19884. pbxlibdir=""
  19885. # if --with-BLUETOOTH=DIR has been specified, use it.
  19886. if test "x${BLUETOOTH_DIR}" != "x"; then
  19887. if test -d ${BLUETOOTH_DIR}/lib; then
  19888. pbxlibdir="-L${BLUETOOTH_DIR}/lib"
  19889. else
  19890. pbxlibdir="-L${BLUETOOTH_DIR}"
  19891. fi
  19892. fi
  19893. pbxfuncname="ba2str"
  19894. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19895. AST_BLUETOOTH_FOUND=yes
  19896. else
  19897. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19898. CFLAGS="${CFLAGS} "
  19899. as_ac_Lib=`$as_echo "ac_cv_lib_bluetooth_${pbxfuncname}" | $as_tr_sh`
  19900. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lbluetooth" >&5
  19901. $as_echo_n "checking for ${pbxfuncname} in -lbluetooth... " >&6; }
  19902. if eval \${$as_ac_Lib+:} false; then :
  19903. $as_echo_n "(cached) " >&6
  19904. else
  19905. ac_check_lib_save_LIBS=$LIBS
  19906. LIBS="-lbluetooth ${pbxlibdir} $LIBS"
  19907. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  19908. /* end confdefs.h. */
  19909. /* Override any GCC internal prototype to avoid an error.
  19910. Use char because int might match the return type of a GCC
  19911. builtin and then its argument prototype would still apply. */
  19912. #ifdef __cplusplus
  19913. extern "C"
  19914. #endif
  19915. char ${pbxfuncname} ();
  19916. int
  19917. main ()
  19918. {
  19919. return ${pbxfuncname} ();
  19920. ;
  19921. return 0;
  19922. }
  19923. _ACEOF
  19924. if ac_fn_c_try_link "$LINENO"; then :
  19925. eval "$as_ac_Lib=yes"
  19926. else
  19927. eval "$as_ac_Lib=no"
  19928. fi
  19929. rm -f core conftest.err conftest.$ac_objext \
  19930. conftest$ac_exeext conftest.$ac_ext
  19931. LIBS=$ac_check_lib_save_LIBS
  19932. fi
  19933. eval ac_res=\$$as_ac_Lib
  19934. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  19935. $as_echo "$ac_res" >&6; }
  19936. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  19937. AST_BLUETOOTH_FOUND=yes
  19938. else
  19939. AST_BLUETOOTH_FOUND=no
  19940. fi
  19941. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  19942. fi
  19943. # now check for the header.
  19944. if test "${AST_BLUETOOTH_FOUND}" = "yes"; then
  19945. BLUETOOTH_LIB="${pbxlibdir} -lbluetooth "
  19946. # if --with-BLUETOOTH=DIR has been specified, use it.
  19947. if test "x${BLUETOOTH_DIR}" != "x"; then
  19948. BLUETOOTH_INCLUDE="-I${BLUETOOTH_DIR}/include"
  19949. fi
  19950. BLUETOOTH_INCLUDE="${BLUETOOTH_INCLUDE} "
  19951. if test "xbluetooth/bluetooth.h" = "x" ; then # no header, assume found
  19952. BLUETOOTH_HEADER_FOUND="1"
  19953. else # check for the header
  19954. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  19955. CPPFLAGS="${CPPFLAGS} ${BLUETOOTH_INCLUDE}"
  19956. ac_fn_c_check_header_mongrel "$LINENO" "bluetooth/bluetooth.h" "ac_cv_header_bluetooth_bluetooth_h" "$ac_includes_default"
  19957. if test "x$ac_cv_header_bluetooth_bluetooth_h" = xyes; then :
  19958. BLUETOOTH_HEADER_FOUND=1
  19959. else
  19960. BLUETOOTH_HEADER_FOUND=0
  19961. fi
  19962. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  19963. fi
  19964. if test "x${BLUETOOTH_HEADER_FOUND}" = "x0" ; then
  19965. BLUETOOTH_LIB=""
  19966. BLUETOOTH_INCLUDE=""
  19967. else
  19968. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  19969. BLUETOOTH_LIB=""
  19970. fi
  19971. PBX_BLUETOOTH=1
  19972. cat >>confdefs.h <<_ACEOF
  19973. #define HAVE_BLUETOOTH 1
  19974. _ACEOF
  19975. fi
  19976. fi
  19977. fi
  19978. # possible places for oss definitions
  19979. if test "x${PBX_OSS}" != "x1" -a "${USE_OSS}" != "no"; then
  19980. pbxlibdir=""
  19981. # if --with-OSS=DIR has been specified, use it.
  19982. if test "x${OSS_DIR}" != "x"; then
  19983. if test -d ${OSS_DIR}/lib; then
  19984. pbxlibdir="-L${OSS_DIR}/lib"
  19985. else
  19986. pbxlibdir="-L${OSS_DIR}"
  19987. fi
  19988. fi
  19989. pbxfuncname=""
  19990. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  19991. AST_OSS_FOUND=yes
  19992. else
  19993. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  19994. CFLAGS="${CFLAGS} "
  19995. as_ac_Lib=`$as_echo "ac_cv_lib_ossaudio_${pbxfuncname}" | $as_tr_sh`
  19996. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lossaudio" >&5
  19997. $as_echo_n "checking for ${pbxfuncname} in -lossaudio... " >&6; }
  19998. if eval \${$as_ac_Lib+:} false; then :
  19999. $as_echo_n "(cached) " >&6
  20000. else
  20001. ac_check_lib_save_LIBS=$LIBS
  20002. LIBS="-lossaudio ${pbxlibdir} $LIBS"
  20003. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20004. /* end confdefs.h. */
  20005. /* Override any GCC internal prototype to avoid an error.
  20006. Use char because int might match the return type of a GCC
  20007. builtin and then its argument prototype would still apply. */
  20008. #ifdef __cplusplus
  20009. extern "C"
  20010. #endif
  20011. char ${pbxfuncname} ();
  20012. int
  20013. main ()
  20014. {
  20015. return ${pbxfuncname} ();
  20016. ;
  20017. return 0;
  20018. }
  20019. _ACEOF
  20020. if ac_fn_c_try_link "$LINENO"; then :
  20021. eval "$as_ac_Lib=yes"
  20022. else
  20023. eval "$as_ac_Lib=no"
  20024. fi
  20025. rm -f core conftest.err conftest.$ac_objext \
  20026. conftest$ac_exeext conftest.$ac_ext
  20027. LIBS=$ac_check_lib_save_LIBS
  20028. fi
  20029. eval ac_res=\$$as_ac_Lib
  20030. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20031. $as_echo "$ac_res" >&6; }
  20032. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20033. AST_OSS_FOUND=yes
  20034. else
  20035. AST_OSS_FOUND=no
  20036. fi
  20037. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20038. fi
  20039. # now check for the header.
  20040. if test "${AST_OSS_FOUND}" = "yes"; then
  20041. OSS_LIB="${pbxlibdir} -lossaudio "
  20042. # if --with-OSS=DIR has been specified, use it.
  20043. if test "x${OSS_DIR}" != "x"; then
  20044. OSS_INCLUDE="-I${OSS_DIR}/include"
  20045. fi
  20046. OSS_INCLUDE="${OSS_INCLUDE} "
  20047. if test "xlinux/soundcard.h" = "x" ; then # no header, assume found
  20048. OSS_HEADER_FOUND="1"
  20049. else # check for the header
  20050. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20051. CPPFLAGS="${CPPFLAGS} ${OSS_INCLUDE}"
  20052. ac_fn_c_check_header_mongrel "$LINENO" "linux/soundcard.h" "ac_cv_header_linux_soundcard_h" "$ac_includes_default"
  20053. if test "x$ac_cv_header_linux_soundcard_h" = xyes; then :
  20054. OSS_HEADER_FOUND=1
  20055. else
  20056. OSS_HEADER_FOUND=0
  20057. fi
  20058. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20059. fi
  20060. if test "x${OSS_HEADER_FOUND}" = "x0" ; then
  20061. OSS_LIB=""
  20062. OSS_INCLUDE=""
  20063. else
  20064. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20065. OSS_LIB=""
  20066. fi
  20067. PBX_OSS=1
  20068. cat >>confdefs.h <<_ACEOF
  20069. #define HAVE_OSS 1
  20070. _ACEOF
  20071. fi
  20072. fi
  20073. fi
  20074. if test "x${PBX_OSS}" != "x1" -a "${USE_OSS}" != "no"; then
  20075. pbxlibdir=""
  20076. # if --with-OSS=DIR has been specified, use it.
  20077. if test "x${OSS_DIR}" != "x"; then
  20078. if test -d ${OSS_DIR}/lib; then
  20079. pbxlibdir="-L${OSS_DIR}/lib"
  20080. else
  20081. pbxlibdir="-L${OSS_DIR}"
  20082. fi
  20083. fi
  20084. pbxfuncname=""
  20085. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20086. AST_OSS_FOUND=yes
  20087. else
  20088. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20089. CFLAGS="${CFLAGS} "
  20090. as_ac_Lib=`$as_echo "ac_cv_lib_ossaudio_${pbxfuncname}" | $as_tr_sh`
  20091. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lossaudio" >&5
  20092. $as_echo_n "checking for ${pbxfuncname} in -lossaudio... " >&6; }
  20093. if eval \${$as_ac_Lib+:} false; then :
  20094. $as_echo_n "(cached) " >&6
  20095. else
  20096. ac_check_lib_save_LIBS=$LIBS
  20097. LIBS="-lossaudio ${pbxlibdir} $LIBS"
  20098. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20099. /* end confdefs.h. */
  20100. /* Override any GCC internal prototype to avoid an error.
  20101. Use char because int might match the return type of a GCC
  20102. builtin and then its argument prototype would still apply. */
  20103. #ifdef __cplusplus
  20104. extern "C"
  20105. #endif
  20106. char ${pbxfuncname} ();
  20107. int
  20108. main ()
  20109. {
  20110. return ${pbxfuncname} ();
  20111. ;
  20112. return 0;
  20113. }
  20114. _ACEOF
  20115. if ac_fn_c_try_link "$LINENO"; then :
  20116. eval "$as_ac_Lib=yes"
  20117. else
  20118. eval "$as_ac_Lib=no"
  20119. fi
  20120. rm -f core conftest.err conftest.$ac_objext \
  20121. conftest$ac_exeext conftest.$ac_ext
  20122. LIBS=$ac_check_lib_save_LIBS
  20123. fi
  20124. eval ac_res=\$$as_ac_Lib
  20125. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20126. $as_echo "$ac_res" >&6; }
  20127. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20128. AST_OSS_FOUND=yes
  20129. else
  20130. AST_OSS_FOUND=no
  20131. fi
  20132. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20133. fi
  20134. # now check for the header.
  20135. if test "${AST_OSS_FOUND}" = "yes"; then
  20136. OSS_LIB="${pbxlibdir} -lossaudio "
  20137. # if --with-OSS=DIR has been specified, use it.
  20138. if test "x${OSS_DIR}" != "x"; then
  20139. OSS_INCLUDE="-I${OSS_DIR}/include"
  20140. fi
  20141. OSS_INCLUDE="${OSS_INCLUDE} "
  20142. if test "xsys/soundcard.h" = "x" ; then # no header, assume found
  20143. OSS_HEADER_FOUND="1"
  20144. else # check for the header
  20145. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20146. CPPFLAGS="${CPPFLAGS} ${OSS_INCLUDE}"
  20147. ac_fn_c_check_header_mongrel "$LINENO" "sys/soundcard.h" "ac_cv_header_sys_soundcard_h" "$ac_includes_default"
  20148. if test "x$ac_cv_header_sys_soundcard_h" = xyes; then :
  20149. OSS_HEADER_FOUND=1
  20150. else
  20151. OSS_HEADER_FOUND=0
  20152. fi
  20153. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20154. fi
  20155. if test "x${OSS_HEADER_FOUND}" = "x0" ; then
  20156. OSS_LIB=""
  20157. OSS_INCLUDE=""
  20158. else
  20159. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20160. OSS_LIB=""
  20161. fi
  20162. PBX_OSS=1
  20163. cat >>confdefs.h <<_ACEOF
  20164. #define HAVE_OSS 1
  20165. _ACEOF
  20166. fi
  20167. fi
  20168. fi
  20169. if test "x${PBX_OSS}" != "x1" -a "${USE_OSS}" != "no"; then
  20170. pbxlibdir=""
  20171. # if --with-OSS=DIR has been specified, use it.
  20172. if test "x${OSS_DIR}" != "x"; then
  20173. if test -d ${OSS_DIR}/lib; then
  20174. pbxlibdir="-L${OSS_DIR}/lib"
  20175. else
  20176. pbxlibdir="-L${OSS_DIR}"
  20177. fi
  20178. fi
  20179. pbxfuncname="oss_ioctl_mixer"
  20180. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20181. AST_OSS_FOUND=yes
  20182. else
  20183. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20184. CFLAGS="${CFLAGS} "
  20185. as_ac_Lib=`$as_echo "ac_cv_lib_ossaudio_${pbxfuncname}" | $as_tr_sh`
  20186. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lossaudio" >&5
  20187. $as_echo_n "checking for ${pbxfuncname} in -lossaudio... " >&6; }
  20188. if eval \${$as_ac_Lib+:} false; then :
  20189. $as_echo_n "(cached) " >&6
  20190. else
  20191. ac_check_lib_save_LIBS=$LIBS
  20192. LIBS="-lossaudio ${pbxlibdir} $LIBS"
  20193. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20194. /* end confdefs.h. */
  20195. /* Override any GCC internal prototype to avoid an error.
  20196. Use char because int might match the return type of a GCC
  20197. builtin and then its argument prototype would still apply. */
  20198. #ifdef __cplusplus
  20199. extern "C"
  20200. #endif
  20201. char ${pbxfuncname} ();
  20202. int
  20203. main ()
  20204. {
  20205. return ${pbxfuncname} ();
  20206. ;
  20207. return 0;
  20208. }
  20209. _ACEOF
  20210. if ac_fn_c_try_link "$LINENO"; then :
  20211. eval "$as_ac_Lib=yes"
  20212. else
  20213. eval "$as_ac_Lib=no"
  20214. fi
  20215. rm -f core conftest.err conftest.$ac_objext \
  20216. conftest$ac_exeext conftest.$ac_ext
  20217. LIBS=$ac_check_lib_save_LIBS
  20218. fi
  20219. eval ac_res=\$$as_ac_Lib
  20220. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20221. $as_echo "$ac_res" >&6; }
  20222. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20223. AST_OSS_FOUND=yes
  20224. else
  20225. AST_OSS_FOUND=no
  20226. fi
  20227. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20228. fi
  20229. # now check for the header.
  20230. if test "${AST_OSS_FOUND}" = "yes"; then
  20231. OSS_LIB="${pbxlibdir} -lossaudio "
  20232. # if --with-OSS=DIR has been specified, use it.
  20233. if test "x${OSS_DIR}" != "x"; then
  20234. OSS_INCLUDE="-I${OSS_DIR}/include"
  20235. fi
  20236. OSS_INCLUDE="${OSS_INCLUDE} "
  20237. if test "xsoundcard.h" = "x" ; then # no header, assume found
  20238. OSS_HEADER_FOUND="1"
  20239. else # check for the header
  20240. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20241. CPPFLAGS="${CPPFLAGS} ${OSS_INCLUDE}"
  20242. ac_fn_c_check_header_mongrel "$LINENO" "soundcard.h" "ac_cv_header_soundcard_h" "$ac_includes_default"
  20243. if test "x$ac_cv_header_soundcard_h" = xyes; then :
  20244. OSS_HEADER_FOUND=1
  20245. else
  20246. OSS_HEADER_FOUND=0
  20247. fi
  20248. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20249. fi
  20250. if test "x${OSS_HEADER_FOUND}" = "x0" ; then
  20251. OSS_LIB=""
  20252. OSS_INCLUDE=""
  20253. else
  20254. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20255. OSS_LIB=""
  20256. fi
  20257. PBX_OSS=1
  20258. cat >>confdefs.h <<_ACEOF
  20259. #define HAVE_OSS 1
  20260. _ACEOF
  20261. fi
  20262. fi
  20263. fi
  20264. PG_CONFIG=No
  20265. if test "${USE_PGSQL}" != "no"; then
  20266. if test "x${PGSQL_DIR}" != "x"; then
  20267. if test -n "$ac_tool_prefix"; then
  20268. # Extract the first word of "${ac_tool_prefix}pg_config", so it can be a program name with args.
  20269. set dummy ${ac_tool_prefix}pg_config; ac_word=$2
  20270. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20271. $as_echo_n "checking for $ac_word... " >&6; }
  20272. if ${ac_cv_path_PG_CONFIG+:} false; then :
  20273. $as_echo_n "(cached) " >&6
  20274. else
  20275. case $PG_CONFIG in
  20276. [\\/]* | ?:[\\/]*)
  20277. ac_cv_path_PG_CONFIG="$PG_CONFIG" # Let the user override the test with a path.
  20278. ;;
  20279. *)
  20280. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20281. for as_dir in ${PGSQL_DIR}/bin
  20282. do
  20283. IFS=$as_save_IFS
  20284. test -z "$as_dir" && as_dir=.
  20285. for ac_exec_ext in '' $ac_executable_extensions; do
  20286. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20287. ac_cv_path_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20288. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20289. break 2
  20290. fi
  20291. done
  20292. done
  20293. IFS=$as_save_IFS
  20294. ;;
  20295. esac
  20296. fi
  20297. PG_CONFIG=$ac_cv_path_PG_CONFIG
  20298. if test -n "$PG_CONFIG"; then
  20299. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PG_CONFIG" >&5
  20300. $as_echo "$PG_CONFIG" >&6; }
  20301. else
  20302. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20303. $as_echo "no" >&6; }
  20304. fi
  20305. fi
  20306. if test -z "$ac_cv_path_PG_CONFIG"; then
  20307. ac_pt_PG_CONFIG=$PG_CONFIG
  20308. # Extract the first word of "pg_config", so it can be a program name with args.
  20309. set dummy pg_config; ac_word=$2
  20310. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20311. $as_echo_n "checking for $ac_word... " >&6; }
  20312. if ${ac_cv_path_ac_pt_PG_CONFIG+:} false; then :
  20313. $as_echo_n "(cached) " >&6
  20314. else
  20315. case $ac_pt_PG_CONFIG in
  20316. [\\/]* | ?:[\\/]*)
  20317. ac_cv_path_ac_pt_PG_CONFIG="$ac_pt_PG_CONFIG" # Let the user override the test with a path.
  20318. ;;
  20319. *)
  20320. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20321. for as_dir in ${PGSQL_DIR}/bin
  20322. do
  20323. IFS=$as_save_IFS
  20324. test -z "$as_dir" && as_dir=.
  20325. for ac_exec_ext in '' $ac_executable_extensions; do
  20326. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20327. ac_cv_path_ac_pt_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20328. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20329. break 2
  20330. fi
  20331. done
  20332. done
  20333. IFS=$as_save_IFS
  20334. ;;
  20335. esac
  20336. fi
  20337. ac_pt_PG_CONFIG=$ac_cv_path_ac_pt_PG_CONFIG
  20338. if test -n "$ac_pt_PG_CONFIG"; then
  20339. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PG_CONFIG" >&5
  20340. $as_echo "$ac_pt_PG_CONFIG" >&6; }
  20341. else
  20342. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20343. $as_echo "no" >&6; }
  20344. fi
  20345. if test "x$ac_pt_PG_CONFIG" = x; then
  20346. PG_CONFIG="No"
  20347. else
  20348. case $cross_compiling:$ac_tool_warned in
  20349. yes:)
  20350. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  20351. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  20352. ac_tool_warned=yes ;;
  20353. esac
  20354. PG_CONFIG=$ac_pt_PG_CONFIG
  20355. fi
  20356. else
  20357. PG_CONFIG="$ac_cv_path_PG_CONFIG"
  20358. fi
  20359. if test x"${PG_CONFIG}" = xNo; then
  20360. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  20361. $as_echo "$as_me: ***" >&6;}
  20362. { $as_echo "$as_me:${as_lineno-$LINENO}: *** pg_config was not found in the path you specified:" >&5
  20363. $as_echo "$as_me: *** pg_config was not found in the path you specified:" >&6;}
  20364. { $as_echo "$as_me:${as_lineno-$LINENO}: *** ${PGSQL_DIR}/bin" >&5
  20365. $as_echo "$as_me: *** ${PGSQL_DIR}/bin" >&6;}
  20366. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  20367. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  20368. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-postgres" >&5
  20369. $as_echo "$as_me: *** including --without-postgres" >&6;}
  20370. exit 1
  20371. fi
  20372. else
  20373. if test -n "$ac_tool_prefix"; then
  20374. # Extract the first word of "${ac_tool_prefix}pg_config", so it can be a program name with args.
  20375. set dummy ${ac_tool_prefix}pg_config; ac_word=$2
  20376. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20377. $as_echo_n "checking for $ac_word... " >&6; }
  20378. if ${ac_cv_path_PG_CONFIG+:} false; then :
  20379. $as_echo_n "(cached) " >&6
  20380. else
  20381. case $PG_CONFIG in
  20382. [\\/]* | ?:[\\/]*)
  20383. ac_cv_path_PG_CONFIG="$PG_CONFIG" # Let the user override the test with a path.
  20384. ;;
  20385. *)
  20386. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20387. for as_dir in $PATH
  20388. do
  20389. IFS=$as_save_IFS
  20390. test -z "$as_dir" && as_dir=.
  20391. for ac_exec_ext in '' $ac_executable_extensions; do
  20392. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20393. ac_cv_path_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20394. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20395. break 2
  20396. fi
  20397. done
  20398. done
  20399. IFS=$as_save_IFS
  20400. ;;
  20401. esac
  20402. fi
  20403. PG_CONFIG=$ac_cv_path_PG_CONFIG
  20404. if test -n "$PG_CONFIG"; then
  20405. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PG_CONFIG" >&5
  20406. $as_echo "$PG_CONFIG" >&6; }
  20407. else
  20408. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20409. $as_echo "no" >&6; }
  20410. fi
  20411. fi
  20412. if test -z "$ac_cv_path_PG_CONFIG"; then
  20413. ac_pt_PG_CONFIG=$PG_CONFIG
  20414. # Extract the first word of "pg_config", so it can be a program name with args.
  20415. set dummy pg_config; ac_word=$2
  20416. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  20417. $as_echo_n "checking for $ac_word... " >&6; }
  20418. if ${ac_cv_path_ac_pt_PG_CONFIG+:} false; then :
  20419. $as_echo_n "(cached) " >&6
  20420. else
  20421. case $ac_pt_PG_CONFIG in
  20422. [\\/]* | ?:[\\/]*)
  20423. ac_cv_path_ac_pt_PG_CONFIG="$ac_pt_PG_CONFIG" # Let the user override the test with a path.
  20424. ;;
  20425. *)
  20426. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  20427. for as_dir in $PATH
  20428. do
  20429. IFS=$as_save_IFS
  20430. test -z "$as_dir" && as_dir=.
  20431. for ac_exec_ext in '' $ac_executable_extensions; do
  20432. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  20433. ac_cv_path_ac_pt_PG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  20434. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  20435. break 2
  20436. fi
  20437. done
  20438. done
  20439. IFS=$as_save_IFS
  20440. ;;
  20441. esac
  20442. fi
  20443. ac_pt_PG_CONFIG=$ac_cv_path_ac_pt_PG_CONFIG
  20444. if test -n "$ac_pt_PG_CONFIG"; then
  20445. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PG_CONFIG" >&5
  20446. $as_echo "$ac_pt_PG_CONFIG" >&6; }
  20447. else
  20448. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20449. $as_echo "no" >&6; }
  20450. fi
  20451. if test "x$ac_pt_PG_CONFIG" = x; then
  20452. PG_CONFIG="No"
  20453. else
  20454. case $cross_compiling:$ac_tool_warned in
  20455. yes:)
  20456. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  20457. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  20458. ac_tool_warned=yes ;;
  20459. esac
  20460. PG_CONFIG=$ac_pt_PG_CONFIG
  20461. fi
  20462. else
  20463. PG_CONFIG="$ac_cv_path_PG_CONFIG"
  20464. fi
  20465. fi
  20466. fi
  20467. if test "${PG_CONFIG}" != No; then
  20468. PGSQL_libdir=`${PG_CONFIG} --libdir`
  20469. PGSQL_includedir=`${PG_CONFIG} --includedir`
  20470. if test "x$?" != "x0" ; then
  20471. if test -n "${PGSQL_MANDATORY}" ; then
  20472. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  20473. $as_echo "$as_me: ***" >&6;}
  20474. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The PostgreSQL installation on this system appears to be broken." >&5
  20475. $as_echo "$as_me: *** The PostgreSQL installation on this system appears to be broken." >&6;}
  20476. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  20477. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  20478. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-postgres" >&5
  20479. $as_echo "$as_me: *** including --without-postgres" >&6;}
  20480. exit 1
  20481. fi
  20482. else
  20483. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PQescapeStringConn in -lpq" >&5
  20484. $as_echo_n "checking for PQescapeStringConn in -lpq... " >&6; }
  20485. if ${ac_cv_lib_pq_PQescapeStringConn+:} false; then :
  20486. $as_echo_n "(cached) " >&6
  20487. else
  20488. ac_check_lib_save_LIBS=$LIBS
  20489. LIBS="-lpq -L${PGSQL_libdir} -lz $LIBS"
  20490. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20491. /* end confdefs.h. */
  20492. /* Override any GCC internal prototype to avoid an error.
  20493. Use char because int might match the return type of a GCC
  20494. builtin and then its argument prototype would still apply. */
  20495. #ifdef __cplusplus
  20496. extern "C"
  20497. #endif
  20498. char PQescapeStringConn ();
  20499. int
  20500. main ()
  20501. {
  20502. return PQescapeStringConn ();
  20503. ;
  20504. return 0;
  20505. }
  20506. _ACEOF
  20507. if ac_fn_c_try_link "$LINENO"; then :
  20508. ac_cv_lib_pq_PQescapeStringConn=yes
  20509. else
  20510. ac_cv_lib_pq_PQescapeStringConn=no
  20511. fi
  20512. rm -f core conftest.err conftest.$ac_objext \
  20513. conftest$ac_exeext conftest.$ac_ext
  20514. LIBS=$ac_check_lib_save_LIBS
  20515. fi
  20516. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pq_PQescapeStringConn" >&5
  20517. $as_echo "$ac_cv_lib_pq_PQescapeStringConn" >&6; }
  20518. if test "x$ac_cv_lib_pq_PQescapeStringConn" = xyes; then :
  20519. cat >>confdefs.h <<_ACEOF
  20520. #define HAVE_PGSQL 1
  20521. _ACEOF
  20522. fi
  20523. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pg_encoding_to_char within Postgres headers" >&5
  20524. $as_echo_n "checking for pg_encoding_to_char within Postgres headers... " >&6; }
  20525. old_CFLAGS=${CFLAGS}
  20526. CFLAGS="${CFLAGS} -I${PGSQL_includedir} -Werror"
  20527. old_LDFLAGS=${LDFLAGS}
  20528. LDFLAGS="${LDFLAGS} -L${PGSQL_libdir} -lpq -lz"
  20529. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20530. /* end confdefs.h. */
  20531. #include <libpq-fe.h>
  20532. int
  20533. main ()
  20534. {
  20535. const char *foo = pg_encoding_to_char(1)
  20536. ;
  20537. return 0;
  20538. }
  20539. _ACEOF
  20540. if ac_fn_c_try_link "$LINENO"; then :
  20541. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  20542. $as_echo "yes" >&6; }
  20543. cat >>confdefs.h <<_ACEOF
  20544. #define HAVE_PGSQL_pg_encoding_to_char 1
  20545. _ACEOF
  20546. else
  20547. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20548. $as_echo "no" >&6; }
  20549. fi
  20550. rm -f core conftest.err conftest.$ac_objext \
  20551. conftest$ac_exeext conftest.$ac_ext
  20552. CFLAGS=${old_CFLAGS}
  20553. LDFLAGS=${old_LDFLAGS}
  20554. if test "${ac_cv_lib_pq_PQescapeStringConn}" = "yes"; then
  20555. PGSQL_LIB="-L${PGSQL_libdir} -lpq -lz"
  20556. PGSQL_INCLUDE="-I${PGSQL_includedir}"
  20557. PBX_PGSQL=1
  20558. elif test -n "${PGSQL_MANDATORY}";
  20559. then
  20560. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  20561. $as_echo "$as_me: ***" >&6;}
  20562. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The PostgreSQL installation on this system appears to be broken." >&5
  20563. $as_echo "$as_me: *** The PostgreSQL installation on this system appears to be broken." >&6;}
  20564. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  20565. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  20566. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-postgres" >&5
  20567. $as_echo "$as_me: *** including --without-postgres" >&6;}
  20568. exit 1
  20569. fi
  20570. fi
  20571. fi
  20572. if test "x${PBX_PJPROJECT}" != "x1" -a "${USE_PJPROJECT}" != "no"; then
  20573. pkg_failed=no
  20574. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PJPROJECT" >&5
  20575. $as_echo_n "checking for PJPROJECT... " >&6; }
  20576. if test -n "$PJPROJECT_CFLAGS"; then
  20577. pkg_cv_PJPROJECT_CFLAGS="$PJPROJECT_CFLAGS"
  20578. elif test -n "$PKG_CONFIG"; then
  20579. if test -n "$PKG_CONFIG" && \
  20580. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpjproject\""; } >&5
  20581. ($PKG_CONFIG --exists --print-errors "libpjproject") 2>&5
  20582. ac_status=$?
  20583. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  20584. test $ac_status = 0; }; then
  20585. pkg_cv_PJPROJECT_CFLAGS=`$PKG_CONFIG --cflags "libpjproject" 2>/dev/null`
  20586. test "x$?" != "x0" && pkg_failed=yes
  20587. else
  20588. pkg_failed=yes
  20589. fi
  20590. else
  20591. pkg_failed=untried
  20592. fi
  20593. if test -n "$PJPROJECT_LIBS"; then
  20594. pkg_cv_PJPROJECT_LIBS="$PJPROJECT_LIBS"
  20595. elif test -n "$PKG_CONFIG"; then
  20596. if test -n "$PKG_CONFIG" && \
  20597. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpjproject\""; } >&5
  20598. ($PKG_CONFIG --exists --print-errors "libpjproject") 2>&5
  20599. ac_status=$?
  20600. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  20601. test $ac_status = 0; }; then
  20602. pkg_cv_PJPROJECT_LIBS=`$PKG_CONFIG --libs "libpjproject" 2>/dev/null`
  20603. test "x$?" != "x0" && pkg_failed=yes
  20604. else
  20605. pkg_failed=yes
  20606. fi
  20607. else
  20608. pkg_failed=untried
  20609. fi
  20610. if test $pkg_failed = yes; then
  20611. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20612. $as_echo "no" >&6; }
  20613. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  20614. _pkg_short_errors_supported=yes
  20615. else
  20616. _pkg_short_errors_supported=no
  20617. fi
  20618. if test $_pkg_short_errors_supported = yes; then
  20619. PJPROJECT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libpjproject" 2>&1`
  20620. else
  20621. PJPROJECT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libpjproject" 2>&1`
  20622. fi
  20623. # Put the nasty error message in config.log where it belongs
  20624. echo "$PJPROJECT_PKG_ERRORS" >&5
  20625. PBX_PJPROJECT=0
  20626. elif test $pkg_failed = untried; then
  20627. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20628. $as_echo "no" >&6; }
  20629. PBX_PJPROJECT=0
  20630. else
  20631. PJPROJECT_CFLAGS=$pkg_cv_PJPROJECT_CFLAGS
  20632. PJPROJECT_LIBS=$pkg_cv_PJPROJECT_LIBS
  20633. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  20634. $as_echo "yes" >&6; }
  20635. PBX_PJPROJECT=1
  20636. PJPROJECT_INCLUDE="$PJPROJECT_CFLAGS"
  20637. PJPROJECT_LIB="$PJPROJECT_LIBS"
  20638. $as_echo "#define HAVE_PJPROJECT 1" >>confdefs.h
  20639. fi
  20640. fi
  20641. if test "x${PBX_PJ_TRANSACTION_GRP_LOCK}" != "x1" -a "${USE_PJ_TRANSACTION_GRP_LOCK}" != "no"; then
  20642. pbxlibdir=""
  20643. # if --with-PJ_TRANSACTION_GRP_LOCK=DIR has been specified, use it.
  20644. if test "x${PJ_TRANSACTION_GRP_LOCK_DIR}" != "x"; then
  20645. if test -d ${PJ_TRANSACTION_GRP_LOCK_DIR}/lib; then
  20646. pbxlibdir="-L${PJ_TRANSACTION_GRP_LOCK_DIR}/lib"
  20647. else
  20648. pbxlibdir="-L${PJ_TRANSACTION_GRP_LOCK_DIR}"
  20649. fi
  20650. fi
  20651. pbxfuncname="pjsip_tsx_create_uac2"
  20652. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20653. AST_PJ_TRANSACTION_GRP_LOCK_FOUND=yes
  20654. else
  20655. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20656. CFLAGS="${CFLAGS} $PJPROJECT_CFLAGS"
  20657. as_ac_Lib=`$as_echo "ac_cv_lib_pjsip_${pbxfuncname}" | $as_tr_sh`
  20658. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpjsip" >&5
  20659. $as_echo_n "checking for ${pbxfuncname} in -lpjsip... " >&6; }
  20660. if eval \${$as_ac_Lib+:} false; then :
  20661. $as_echo_n "(cached) " >&6
  20662. else
  20663. ac_check_lib_save_LIBS=$LIBS
  20664. LIBS="-lpjsip ${pbxlibdir} $PJPROJECT_LIBS $LIBS"
  20665. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20666. /* end confdefs.h. */
  20667. /* Override any GCC internal prototype to avoid an error.
  20668. Use char because int might match the return type of a GCC
  20669. builtin and then its argument prototype would still apply. */
  20670. #ifdef __cplusplus
  20671. extern "C"
  20672. #endif
  20673. char ${pbxfuncname} ();
  20674. int
  20675. main ()
  20676. {
  20677. return ${pbxfuncname} ();
  20678. ;
  20679. return 0;
  20680. }
  20681. _ACEOF
  20682. if ac_fn_c_try_link "$LINENO"; then :
  20683. eval "$as_ac_Lib=yes"
  20684. else
  20685. eval "$as_ac_Lib=no"
  20686. fi
  20687. rm -f core conftest.err conftest.$ac_objext \
  20688. conftest$ac_exeext conftest.$ac_ext
  20689. LIBS=$ac_check_lib_save_LIBS
  20690. fi
  20691. eval ac_res=\$$as_ac_Lib
  20692. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20693. $as_echo "$ac_res" >&6; }
  20694. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20695. AST_PJ_TRANSACTION_GRP_LOCK_FOUND=yes
  20696. else
  20697. AST_PJ_TRANSACTION_GRP_LOCK_FOUND=no
  20698. fi
  20699. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20700. fi
  20701. # now check for the header.
  20702. if test "${AST_PJ_TRANSACTION_GRP_LOCK_FOUND}" = "yes"; then
  20703. PJ_TRANSACTION_GRP_LOCK_LIB="${pbxlibdir} -lpjsip $PJPROJECT_LIBS"
  20704. # if --with-PJ_TRANSACTION_GRP_LOCK=DIR has been specified, use it.
  20705. if test "x${PJ_TRANSACTION_GRP_LOCK_DIR}" != "x"; then
  20706. PJ_TRANSACTION_GRP_LOCK_INCLUDE="-I${PJ_TRANSACTION_GRP_LOCK_DIR}/include"
  20707. fi
  20708. PJ_TRANSACTION_GRP_LOCK_INCLUDE="${PJ_TRANSACTION_GRP_LOCK_INCLUDE} $PJPROJECT_CFLAGS"
  20709. if test "xpjsip.h" = "x" ; then # no header, assume found
  20710. PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND="1"
  20711. else # check for the header
  20712. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20713. CPPFLAGS="${CPPFLAGS} ${PJ_TRANSACTION_GRP_LOCK_INCLUDE}"
  20714. ac_fn_c_check_header_mongrel "$LINENO" "pjsip.h" "ac_cv_header_pjsip_h" "$ac_includes_default"
  20715. if test "x$ac_cv_header_pjsip_h" = xyes; then :
  20716. PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND=1
  20717. else
  20718. PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND=0
  20719. fi
  20720. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20721. fi
  20722. if test "x${PJ_TRANSACTION_GRP_LOCK_HEADER_FOUND}" = "x0" ; then
  20723. PJ_TRANSACTION_GRP_LOCK_LIB=""
  20724. PJ_TRANSACTION_GRP_LOCK_INCLUDE=""
  20725. else
  20726. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20727. PJ_TRANSACTION_GRP_LOCK_LIB=""
  20728. fi
  20729. PBX_PJ_TRANSACTION_GRP_LOCK=1
  20730. cat >>confdefs.h <<_ACEOF
  20731. #define HAVE_PJ_TRANSACTION_GRP_LOCK 1
  20732. _ACEOF
  20733. fi
  20734. fi
  20735. fi
  20736. saved_cppflags="${CPPFLAGS}"
  20737. saved_libs="${LIBS}"
  20738. CPPFLAGS="${CPPFLAGS} ${PJPROJECT_CFLAGS}"
  20739. LIBS="${LIBS} ${PJPROJECT_LIBS}"
  20740. if test "x${PBX_PJSIP_REPLACE_MEDIA_STREAM}" != "x1" -a "${USE_PJSIP_REPLACE_MEDIA_STREAM}" != "no"; then
  20741. if test "x" != "x"; then
  20742. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for " >&5
  20743. $as_echo_n "checking for ... " >&6; }
  20744. else
  20745. { $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
  20746. $as_echo_n "checking if \"pjmedia_mod_offer_flag flag = PJMEDIA_SDP_NEG_ALLOW_MEDIA_CHANGE\" compiles using pjmedia.h... " >&6; }
  20747. fi
  20748. saved_cppflags="${CPPFLAGS}"
  20749. if test "x${PJSIP_REPLACE_MEDIA_STREAM_DIR}" != "x"; then
  20750. PJSIP_REPLACE_MEDIA_STREAM_INCLUDE="-I${PJSIP_REPLACE_MEDIA_STREAM_DIR}/include"
  20751. fi
  20752. CPPFLAGS="${CPPFLAGS} ${PJSIP_REPLACE_MEDIA_STREAM_INCLUDE}"
  20753. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20754. /* end confdefs.h. */
  20755. #include <pjmedia.h>
  20756. int
  20757. main ()
  20758. {
  20759. pjmedia_mod_offer_flag flag = PJMEDIA_SDP_NEG_ALLOW_MEDIA_CHANGE;
  20760. ;
  20761. return 0;
  20762. }
  20763. _ACEOF
  20764. if ac_fn_c_try_compile "$LINENO"; then :
  20765. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  20766. $as_echo "yes" >&6; }
  20767. PBX_PJSIP_REPLACE_MEDIA_STREAM=1
  20768. $as_echo "#define HAVE_PJSIP_REPLACE_MEDIA_STREAM 1" >>confdefs.h
  20769. else
  20770. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  20771. $as_echo "no" >&6; }
  20772. fi
  20773. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  20774. CPPFLAGS="${saved_cppflags}"
  20775. fi
  20776. LIBS="${saved_libs}"
  20777. CPPFLAGS="${saved_cppflags}"
  20778. if test "x${PBX_PJSIP_GET_DEST_INFO}" != "x1" -a "${USE_PJSIP_GET_DEST_INFO}" != "no"; then
  20779. pbxlibdir=""
  20780. # if --with-PJSIP_GET_DEST_INFO=DIR has been specified, use it.
  20781. if test "x${PJSIP_GET_DEST_INFO_DIR}" != "x"; then
  20782. if test -d ${PJSIP_GET_DEST_INFO_DIR}/lib; then
  20783. pbxlibdir="-L${PJSIP_GET_DEST_INFO_DIR}/lib"
  20784. else
  20785. pbxlibdir="-L${PJSIP_GET_DEST_INFO_DIR}"
  20786. fi
  20787. fi
  20788. pbxfuncname="pjsip_get_dest_info"
  20789. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20790. AST_PJSIP_GET_DEST_INFO_FOUND=yes
  20791. else
  20792. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20793. CFLAGS="${CFLAGS} $PJPROJECT_CFLAGS"
  20794. as_ac_Lib=`$as_echo "ac_cv_lib_pjsip_${pbxfuncname}" | $as_tr_sh`
  20795. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpjsip" >&5
  20796. $as_echo_n "checking for ${pbxfuncname} in -lpjsip... " >&6; }
  20797. if eval \${$as_ac_Lib+:} false; then :
  20798. $as_echo_n "(cached) " >&6
  20799. else
  20800. ac_check_lib_save_LIBS=$LIBS
  20801. LIBS="-lpjsip ${pbxlibdir} $PJPROJECT_LIBS $LIBS"
  20802. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20803. /* end confdefs.h. */
  20804. /* Override any GCC internal prototype to avoid an error.
  20805. Use char because int might match the return type of a GCC
  20806. builtin and then its argument prototype would still apply. */
  20807. #ifdef __cplusplus
  20808. extern "C"
  20809. #endif
  20810. char ${pbxfuncname} ();
  20811. int
  20812. main ()
  20813. {
  20814. return ${pbxfuncname} ();
  20815. ;
  20816. return 0;
  20817. }
  20818. _ACEOF
  20819. if ac_fn_c_try_link "$LINENO"; then :
  20820. eval "$as_ac_Lib=yes"
  20821. else
  20822. eval "$as_ac_Lib=no"
  20823. fi
  20824. rm -f core conftest.err conftest.$ac_objext \
  20825. conftest$ac_exeext conftest.$ac_ext
  20826. LIBS=$ac_check_lib_save_LIBS
  20827. fi
  20828. eval ac_res=\$$as_ac_Lib
  20829. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20830. $as_echo "$ac_res" >&6; }
  20831. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20832. AST_PJSIP_GET_DEST_INFO_FOUND=yes
  20833. else
  20834. AST_PJSIP_GET_DEST_INFO_FOUND=no
  20835. fi
  20836. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20837. fi
  20838. # now check for the header.
  20839. if test "${AST_PJSIP_GET_DEST_INFO_FOUND}" = "yes"; then
  20840. PJSIP_GET_DEST_INFO_LIB="${pbxlibdir} -lpjsip $PJPROJECT_LIBS"
  20841. # if --with-PJSIP_GET_DEST_INFO=DIR has been specified, use it.
  20842. if test "x${PJSIP_GET_DEST_INFO_DIR}" != "x"; then
  20843. PJSIP_GET_DEST_INFO_INCLUDE="-I${PJSIP_GET_DEST_INFO_DIR}/include"
  20844. fi
  20845. PJSIP_GET_DEST_INFO_INCLUDE="${PJSIP_GET_DEST_INFO_INCLUDE} $PJPROJECT_CFLAGS"
  20846. if test "xpjsip.h" = "x" ; then # no header, assume found
  20847. PJSIP_GET_DEST_INFO_HEADER_FOUND="1"
  20848. else # check for the header
  20849. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20850. CPPFLAGS="${CPPFLAGS} ${PJSIP_GET_DEST_INFO_INCLUDE}"
  20851. ac_fn_c_check_header_mongrel "$LINENO" "pjsip.h" "ac_cv_header_pjsip_h" "$ac_includes_default"
  20852. if test "x$ac_cv_header_pjsip_h" = xyes; then :
  20853. PJSIP_GET_DEST_INFO_HEADER_FOUND=1
  20854. else
  20855. PJSIP_GET_DEST_INFO_HEADER_FOUND=0
  20856. fi
  20857. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20858. fi
  20859. if test "x${PJSIP_GET_DEST_INFO_HEADER_FOUND}" = "x0" ; then
  20860. PJSIP_GET_DEST_INFO_LIB=""
  20861. PJSIP_GET_DEST_INFO_INCLUDE=""
  20862. else
  20863. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20864. PJSIP_GET_DEST_INFO_LIB=""
  20865. fi
  20866. PBX_PJSIP_GET_DEST_INFO=1
  20867. cat >>confdefs.h <<_ACEOF
  20868. #define HAVE_PJSIP_GET_DEST_INFO 1
  20869. _ACEOF
  20870. fi
  20871. fi
  20872. fi
  20873. if test "x${PBX_PJ_SSL_CERT_LOAD_FROM_FILES2}" != "x1" -a "${USE_PJ_SSL_CERT_LOAD_FROM_FILES2}" != "no"; then
  20874. pbxlibdir=""
  20875. # if --with-PJ_SSL_CERT_LOAD_FROM_FILES2=DIR has been specified, use it.
  20876. if test "x${PJ_SSL_CERT_LOAD_FROM_FILES2_DIR}" != "x"; then
  20877. if test -d ${PJ_SSL_CERT_LOAD_FROM_FILES2_DIR}/lib; then
  20878. pbxlibdir="-L${PJ_SSL_CERT_LOAD_FROM_FILES2_DIR}/lib"
  20879. else
  20880. pbxlibdir="-L${PJ_SSL_CERT_LOAD_FROM_FILES2_DIR}"
  20881. fi
  20882. fi
  20883. pbxfuncname="pj_ssl_cert_load_from_files2"
  20884. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20885. AST_PJ_SSL_CERT_LOAD_FROM_FILES2_FOUND=yes
  20886. else
  20887. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20888. CFLAGS="${CFLAGS} $PJPROJECT_CFLAGS"
  20889. as_ac_Lib=`$as_echo "ac_cv_lib_pj_${pbxfuncname}" | $as_tr_sh`
  20890. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpj" >&5
  20891. $as_echo_n "checking for ${pbxfuncname} in -lpj... " >&6; }
  20892. if eval \${$as_ac_Lib+:} false; then :
  20893. $as_echo_n "(cached) " >&6
  20894. else
  20895. ac_check_lib_save_LIBS=$LIBS
  20896. LIBS="-lpj ${pbxlibdir} $PJPROJECT_LIBS $LIBS"
  20897. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20898. /* end confdefs.h. */
  20899. /* Override any GCC internal prototype to avoid an error.
  20900. Use char because int might match the return type of a GCC
  20901. builtin and then its argument prototype would still apply. */
  20902. #ifdef __cplusplus
  20903. extern "C"
  20904. #endif
  20905. char ${pbxfuncname} ();
  20906. int
  20907. main ()
  20908. {
  20909. return ${pbxfuncname} ();
  20910. ;
  20911. return 0;
  20912. }
  20913. _ACEOF
  20914. if ac_fn_c_try_link "$LINENO"; then :
  20915. eval "$as_ac_Lib=yes"
  20916. else
  20917. eval "$as_ac_Lib=no"
  20918. fi
  20919. rm -f core conftest.err conftest.$ac_objext \
  20920. conftest$ac_exeext conftest.$ac_ext
  20921. LIBS=$ac_check_lib_save_LIBS
  20922. fi
  20923. eval ac_res=\$$as_ac_Lib
  20924. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  20925. $as_echo "$ac_res" >&6; }
  20926. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  20927. AST_PJ_SSL_CERT_LOAD_FROM_FILES2_FOUND=yes
  20928. else
  20929. AST_PJ_SSL_CERT_LOAD_FROM_FILES2_FOUND=no
  20930. fi
  20931. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  20932. fi
  20933. # now check for the header.
  20934. if test "${AST_PJ_SSL_CERT_LOAD_FROM_FILES2_FOUND}" = "yes"; then
  20935. PJ_SSL_CERT_LOAD_FROM_FILES2_LIB="${pbxlibdir} -lpj $PJPROJECT_LIBS"
  20936. # if --with-PJ_SSL_CERT_LOAD_FROM_FILES2=DIR has been specified, use it.
  20937. if test "x${PJ_SSL_CERT_LOAD_FROM_FILES2_DIR}" != "x"; then
  20938. PJ_SSL_CERT_LOAD_FROM_FILES2_INCLUDE="-I${PJ_SSL_CERT_LOAD_FROM_FILES2_DIR}/include"
  20939. fi
  20940. PJ_SSL_CERT_LOAD_FROM_FILES2_INCLUDE="${PJ_SSL_CERT_LOAD_FROM_FILES2_INCLUDE} $PJPROJECT_CFLAGS"
  20941. if test "xpjlib.h" = "x" ; then # no header, assume found
  20942. PJ_SSL_CERT_LOAD_FROM_FILES2_HEADER_FOUND="1"
  20943. else # check for the header
  20944. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  20945. CPPFLAGS="${CPPFLAGS} ${PJ_SSL_CERT_LOAD_FROM_FILES2_INCLUDE}"
  20946. ac_fn_c_check_header_mongrel "$LINENO" "pjlib.h" "ac_cv_header_pjlib_h" "$ac_includes_default"
  20947. if test "x$ac_cv_header_pjlib_h" = xyes; then :
  20948. PJ_SSL_CERT_LOAD_FROM_FILES2_HEADER_FOUND=1
  20949. else
  20950. PJ_SSL_CERT_LOAD_FROM_FILES2_HEADER_FOUND=0
  20951. fi
  20952. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  20953. fi
  20954. if test "x${PJ_SSL_CERT_LOAD_FROM_FILES2_HEADER_FOUND}" = "x0" ; then
  20955. PJ_SSL_CERT_LOAD_FROM_FILES2_LIB=""
  20956. PJ_SSL_CERT_LOAD_FROM_FILES2_INCLUDE=""
  20957. else
  20958. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  20959. PJ_SSL_CERT_LOAD_FROM_FILES2_LIB=""
  20960. fi
  20961. PBX_PJ_SSL_CERT_LOAD_FROM_FILES2=1
  20962. cat >>confdefs.h <<_ACEOF
  20963. #define HAVE_PJ_SSL_CERT_LOAD_FROM_FILES2 1
  20964. _ACEOF
  20965. fi
  20966. fi
  20967. fi
  20968. if test "x${PBX_POPT}" != "x1" -a "${USE_POPT}" != "no"; then
  20969. pbxlibdir=""
  20970. # if --with-POPT=DIR has been specified, use it.
  20971. if test "x${POPT_DIR}" != "x"; then
  20972. if test -d ${POPT_DIR}/lib; then
  20973. pbxlibdir="-L${POPT_DIR}/lib"
  20974. else
  20975. pbxlibdir="-L${POPT_DIR}"
  20976. fi
  20977. fi
  20978. pbxfuncname="poptStrerror"
  20979. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  20980. AST_POPT_FOUND=yes
  20981. else
  20982. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  20983. CFLAGS="${CFLAGS} "
  20984. as_ac_Lib=`$as_echo "ac_cv_lib_popt_${pbxfuncname}" | $as_tr_sh`
  20985. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpopt" >&5
  20986. $as_echo_n "checking for ${pbxfuncname} in -lpopt... " >&6; }
  20987. if eval \${$as_ac_Lib+:} false; then :
  20988. $as_echo_n "(cached) " >&6
  20989. else
  20990. ac_check_lib_save_LIBS=$LIBS
  20991. LIBS="-lpopt ${pbxlibdir} $LIBS"
  20992. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  20993. /* end confdefs.h. */
  20994. /* Override any GCC internal prototype to avoid an error.
  20995. Use char because int might match the return type of a GCC
  20996. builtin and then its argument prototype would still apply. */
  20997. #ifdef __cplusplus
  20998. extern "C"
  20999. #endif
  21000. char ${pbxfuncname} ();
  21001. int
  21002. main ()
  21003. {
  21004. return ${pbxfuncname} ();
  21005. ;
  21006. return 0;
  21007. }
  21008. _ACEOF
  21009. if ac_fn_c_try_link "$LINENO"; then :
  21010. eval "$as_ac_Lib=yes"
  21011. else
  21012. eval "$as_ac_Lib=no"
  21013. fi
  21014. rm -f core conftest.err conftest.$ac_objext \
  21015. conftest$ac_exeext conftest.$ac_ext
  21016. LIBS=$ac_check_lib_save_LIBS
  21017. fi
  21018. eval ac_res=\$$as_ac_Lib
  21019. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21020. $as_echo "$ac_res" >&6; }
  21021. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21022. AST_POPT_FOUND=yes
  21023. else
  21024. AST_POPT_FOUND=no
  21025. fi
  21026. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21027. fi
  21028. # now check for the header.
  21029. if test "${AST_POPT_FOUND}" = "yes"; then
  21030. POPT_LIB="${pbxlibdir} -lpopt "
  21031. # if --with-POPT=DIR has been specified, use it.
  21032. if test "x${POPT_DIR}" != "x"; then
  21033. POPT_INCLUDE="-I${POPT_DIR}/include"
  21034. fi
  21035. POPT_INCLUDE="${POPT_INCLUDE} "
  21036. if test "xpopt.h" = "x" ; then # no header, assume found
  21037. POPT_HEADER_FOUND="1"
  21038. else # check for the header
  21039. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21040. CPPFLAGS="${CPPFLAGS} ${POPT_INCLUDE}"
  21041. ac_fn_c_check_header_mongrel "$LINENO" "popt.h" "ac_cv_header_popt_h" "$ac_includes_default"
  21042. if test "x$ac_cv_header_popt_h" = xyes; then :
  21043. POPT_HEADER_FOUND=1
  21044. else
  21045. POPT_HEADER_FOUND=0
  21046. fi
  21047. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21048. fi
  21049. if test "x${POPT_HEADER_FOUND}" = "x0" ; then
  21050. POPT_LIB=""
  21051. POPT_INCLUDE=""
  21052. else
  21053. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21054. POPT_LIB=""
  21055. fi
  21056. PBX_POPT=1
  21057. cat >>confdefs.h <<_ACEOF
  21058. #define HAVE_POPT 1
  21059. _ACEOF
  21060. fi
  21061. fi
  21062. fi
  21063. if test "x${PBX_PORTAUDIO}" != "x1" -a "${USE_PORTAUDIO}" != "no"; then
  21064. pbxlibdir=""
  21065. # if --with-PORTAUDIO=DIR has been specified, use it.
  21066. if test "x${PORTAUDIO_DIR}" != "x"; then
  21067. if test -d ${PORTAUDIO_DIR}/lib; then
  21068. pbxlibdir="-L${PORTAUDIO_DIR}/lib"
  21069. else
  21070. pbxlibdir="-L${PORTAUDIO_DIR}"
  21071. fi
  21072. fi
  21073. pbxfuncname="Pa_GetDeviceCount"
  21074. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21075. AST_PORTAUDIO_FOUND=yes
  21076. else
  21077. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21078. CFLAGS="${CFLAGS} "
  21079. as_ac_Lib=`$as_echo "ac_cv_lib_portaudio_${pbxfuncname}" | $as_tr_sh`
  21080. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lportaudio" >&5
  21081. $as_echo_n "checking for ${pbxfuncname} in -lportaudio... " >&6; }
  21082. if eval \${$as_ac_Lib+:} false; then :
  21083. $as_echo_n "(cached) " >&6
  21084. else
  21085. ac_check_lib_save_LIBS=$LIBS
  21086. LIBS="-lportaudio ${pbxlibdir} $LIBS"
  21087. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21088. /* end confdefs.h. */
  21089. /* Override any GCC internal prototype to avoid an error.
  21090. Use char because int might match the return type of a GCC
  21091. builtin and then its argument prototype would still apply. */
  21092. #ifdef __cplusplus
  21093. extern "C"
  21094. #endif
  21095. char ${pbxfuncname} ();
  21096. int
  21097. main ()
  21098. {
  21099. return ${pbxfuncname} ();
  21100. ;
  21101. return 0;
  21102. }
  21103. _ACEOF
  21104. if ac_fn_c_try_link "$LINENO"; then :
  21105. eval "$as_ac_Lib=yes"
  21106. else
  21107. eval "$as_ac_Lib=no"
  21108. fi
  21109. rm -f core conftest.err conftest.$ac_objext \
  21110. conftest$ac_exeext conftest.$ac_ext
  21111. LIBS=$ac_check_lib_save_LIBS
  21112. fi
  21113. eval ac_res=\$$as_ac_Lib
  21114. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21115. $as_echo "$ac_res" >&6; }
  21116. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21117. AST_PORTAUDIO_FOUND=yes
  21118. else
  21119. AST_PORTAUDIO_FOUND=no
  21120. fi
  21121. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21122. fi
  21123. # now check for the header.
  21124. if test "${AST_PORTAUDIO_FOUND}" = "yes"; then
  21125. PORTAUDIO_LIB="${pbxlibdir} -lportaudio "
  21126. # if --with-PORTAUDIO=DIR has been specified, use it.
  21127. if test "x${PORTAUDIO_DIR}" != "x"; then
  21128. PORTAUDIO_INCLUDE="-I${PORTAUDIO_DIR}/include"
  21129. fi
  21130. PORTAUDIO_INCLUDE="${PORTAUDIO_INCLUDE} "
  21131. if test "xportaudio.h" = "x" ; then # no header, assume found
  21132. PORTAUDIO_HEADER_FOUND="1"
  21133. else # check for the header
  21134. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21135. CPPFLAGS="${CPPFLAGS} ${PORTAUDIO_INCLUDE}"
  21136. ac_fn_c_check_header_mongrel "$LINENO" "portaudio.h" "ac_cv_header_portaudio_h" "$ac_includes_default"
  21137. if test "x$ac_cv_header_portaudio_h" = xyes; then :
  21138. PORTAUDIO_HEADER_FOUND=1
  21139. else
  21140. PORTAUDIO_HEADER_FOUND=0
  21141. fi
  21142. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21143. fi
  21144. if test "x${PORTAUDIO_HEADER_FOUND}" = "x0" ; then
  21145. PORTAUDIO_LIB=""
  21146. PORTAUDIO_INCLUDE=""
  21147. else
  21148. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21149. PORTAUDIO_LIB=""
  21150. fi
  21151. PBX_PORTAUDIO=1
  21152. cat >>confdefs.h <<_ACEOF
  21153. #define HAVE_PORTAUDIO 1
  21154. _ACEOF
  21155. fi
  21156. fi
  21157. fi
  21158. if test "x${PBX_PRI}" != "x1" -a "${USE_PRI}" != "no"; then
  21159. pbxlibdir=""
  21160. # if --with-PRI=DIR has been specified, use it.
  21161. if test "x${PRI_DIR}" != "x"; then
  21162. if test -d ${PRI_DIR}/lib; then
  21163. pbxlibdir="-L${PRI_DIR}/lib"
  21164. else
  21165. pbxlibdir="-L${PRI_DIR}"
  21166. fi
  21167. fi
  21168. pbxfuncname="pri_connected_line_update"
  21169. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21170. AST_PRI_FOUND=yes
  21171. else
  21172. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21173. CFLAGS="${CFLAGS} "
  21174. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21175. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21176. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21177. if eval \${$as_ac_Lib+:} false; then :
  21178. $as_echo_n "(cached) " >&6
  21179. else
  21180. ac_check_lib_save_LIBS=$LIBS
  21181. LIBS="-lpri ${pbxlibdir} $LIBS"
  21182. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21183. /* end confdefs.h. */
  21184. /* Override any GCC internal prototype to avoid an error.
  21185. Use char because int might match the return type of a GCC
  21186. builtin and then its argument prototype would still apply. */
  21187. #ifdef __cplusplus
  21188. extern "C"
  21189. #endif
  21190. char ${pbxfuncname} ();
  21191. int
  21192. main ()
  21193. {
  21194. return ${pbxfuncname} ();
  21195. ;
  21196. return 0;
  21197. }
  21198. _ACEOF
  21199. if ac_fn_c_try_link "$LINENO"; then :
  21200. eval "$as_ac_Lib=yes"
  21201. else
  21202. eval "$as_ac_Lib=no"
  21203. fi
  21204. rm -f core conftest.err conftest.$ac_objext \
  21205. conftest$ac_exeext conftest.$ac_ext
  21206. LIBS=$ac_check_lib_save_LIBS
  21207. fi
  21208. eval ac_res=\$$as_ac_Lib
  21209. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21210. $as_echo "$ac_res" >&6; }
  21211. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21212. AST_PRI_FOUND=yes
  21213. else
  21214. AST_PRI_FOUND=no
  21215. fi
  21216. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21217. fi
  21218. # now check for the header.
  21219. if test "${AST_PRI_FOUND}" = "yes"; then
  21220. PRI_LIB="${pbxlibdir} -lpri "
  21221. # if --with-PRI=DIR has been specified, use it.
  21222. if test "x${PRI_DIR}" != "x"; then
  21223. PRI_INCLUDE="-I${PRI_DIR}/include"
  21224. fi
  21225. PRI_INCLUDE="${PRI_INCLUDE} "
  21226. if test "xlibpri.h" = "x" ; then # no header, assume found
  21227. PRI_HEADER_FOUND="1"
  21228. else # check for the header
  21229. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21230. CPPFLAGS="${CPPFLAGS} ${PRI_INCLUDE}"
  21231. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21232. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21233. PRI_HEADER_FOUND=1
  21234. else
  21235. PRI_HEADER_FOUND=0
  21236. fi
  21237. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21238. fi
  21239. if test "x${PRI_HEADER_FOUND}" = "x0" ; then
  21240. PRI_LIB=""
  21241. PRI_INCLUDE=""
  21242. else
  21243. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21244. PRI_LIB=""
  21245. fi
  21246. PBX_PRI=1
  21247. cat >>confdefs.h <<_ACEOF
  21248. #define HAVE_PRI 1
  21249. _ACEOF
  21250. fi
  21251. fi
  21252. fi
  21253. if test "x${PBX_PRI_SETUP_ACK_INBAND}" != "x1" -a "${USE_PRI_SETUP_ACK_INBAND}" != "no"; then
  21254. pbxlibdir=""
  21255. # if --with-PRI_SETUP_ACK_INBAND=DIR has been specified, use it.
  21256. if test "x${PRI_SETUP_ACK_INBAND_DIR}" != "x"; then
  21257. if test -d ${PRI_SETUP_ACK_INBAND_DIR}/lib; then
  21258. pbxlibdir="-L${PRI_SETUP_ACK_INBAND_DIR}/lib"
  21259. else
  21260. pbxlibdir="-L${PRI_SETUP_ACK_INBAND_DIR}"
  21261. fi
  21262. fi
  21263. pbxfuncname="pri_setup_ack"
  21264. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21265. AST_PRI_SETUP_ACK_INBAND_FOUND=yes
  21266. else
  21267. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21268. CFLAGS="${CFLAGS} "
  21269. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21270. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21271. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21272. if eval \${$as_ac_Lib+:} false; then :
  21273. $as_echo_n "(cached) " >&6
  21274. else
  21275. ac_check_lib_save_LIBS=$LIBS
  21276. LIBS="-lpri ${pbxlibdir} $LIBS"
  21277. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21278. /* end confdefs.h. */
  21279. /* Override any GCC internal prototype to avoid an error.
  21280. Use char because int might match the return type of a GCC
  21281. builtin and then its argument prototype would still apply. */
  21282. #ifdef __cplusplus
  21283. extern "C"
  21284. #endif
  21285. char ${pbxfuncname} ();
  21286. int
  21287. main ()
  21288. {
  21289. return ${pbxfuncname} ();
  21290. ;
  21291. return 0;
  21292. }
  21293. _ACEOF
  21294. if ac_fn_c_try_link "$LINENO"; then :
  21295. eval "$as_ac_Lib=yes"
  21296. else
  21297. eval "$as_ac_Lib=no"
  21298. fi
  21299. rm -f core conftest.err conftest.$ac_objext \
  21300. conftest$ac_exeext conftest.$ac_ext
  21301. LIBS=$ac_check_lib_save_LIBS
  21302. fi
  21303. eval ac_res=\$$as_ac_Lib
  21304. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21305. $as_echo "$ac_res" >&6; }
  21306. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21307. AST_PRI_SETUP_ACK_INBAND_FOUND=yes
  21308. else
  21309. AST_PRI_SETUP_ACK_INBAND_FOUND=no
  21310. fi
  21311. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21312. fi
  21313. # now check for the header.
  21314. if test "${AST_PRI_SETUP_ACK_INBAND_FOUND}" = "yes"; then
  21315. PRI_SETUP_ACK_INBAND_LIB="${pbxlibdir} -lpri "
  21316. # if --with-PRI_SETUP_ACK_INBAND=DIR has been specified, use it.
  21317. if test "x${PRI_SETUP_ACK_INBAND_DIR}" != "x"; then
  21318. PRI_SETUP_ACK_INBAND_INCLUDE="-I${PRI_SETUP_ACK_INBAND_DIR}/include"
  21319. fi
  21320. PRI_SETUP_ACK_INBAND_INCLUDE="${PRI_SETUP_ACK_INBAND_INCLUDE} "
  21321. if test "xlibpri.h" = "x" ; then # no header, assume found
  21322. PRI_SETUP_ACK_INBAND_HEADER_FOUND="1"
  21323. else # check for the header
  21324. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21325. CPPFLAGS="${CPPFLAGS} ${PRI_SETUP_ACK_INBAND_INCLUDE}"
  21326. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21327. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21328. PRI_SETUP_ACK_INBAND_HEADER_FOUND=1
  21329. else
  21330. PRI_SETUP_ACK_INBAND_HEADER_FOUND=0
  21331. fi
  21332. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21333. fi
  21334. if test "x${PRI_SETUP_ACK_INBAND_HEADER_FOUND}" = "x0" ; then
  21335. PRI_SETUP_ACK_INBAND_LIB=""
  21336. PRI_SETUP_ACK_INBAND_INCLUDE=""
  21337. else
  21338. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21339. PRI_SETUP_ACK_INBAND_LIB=""
  21340. fi
  21341. PBX_PRI_SETUP_ACK_INBAND=1
  21342. cat >>confdefs.h <<_ACEOF
  21343. #define HAVE_PRI_SETUP_ACK_INBAND 1
  21344. _ACEOF
  21345. fi
  21346. fi
  21347. fi
  21348. if test "x${PBX_PRI_L2_PERSISTENCE}" != "x1" -a "${USE_PRI_L2_PERSISTENCE}" != "no"; then
  21349. pbxlibdir=""
  21350. # if --with-PRI_L2_PERSISTENCE=DIR has been specified, use it.
  21351. if test "x${PRI_L2_PERSISTENCE_DIR}" != "x"; then
  21352. if test -d ${PRI_L2_PERSISTENCE_DIR}/lib; then
  21353. pbxlibdir="-L${PRI_L2_PERSISTENCE_DIR}/lib"
  21354. else
  21355. pbxlibdir="-L${PRI_L2_PERSISTENCE_DIR}"
  21356. fi
  21357. fi
  21358. pbxfuncname="pri_persistent_layer2_option"
  21359. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21360. AST_PRI_L2_PERSISTENCE_FOUND=yes
  21361. else
  21362. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21363. CFLAGS="${CFLAGS} "
  21364. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21365. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21366. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21367. if eval \${$as_ac_Lib+:} false; then :
  21368. $as_echo_n "(cached) " >&6
  21369. else
  21370. ac_check_lib_save_LIBS=$LIBS
  21371. LIBS="-lpri ${pbxlibdir} $LIBS"
  21372. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21373. /* end confdefs.h. */
  21374. /* Override any GCC internal prototype to avoid an error.
  21375. Use char because int might match the return type of a GCC
  21376. builtin and then its argument prototype would still apply. */
  21377. #ifdef __cplusplus
  21378. extern "C"
  21379. #endif
  21380. char ${pbxfuncname} ();
  21381. int
  21382. main ()
  21383. {
  21384. return ${pbxfuncname} ();
  21385. ;
  21386. return 0;
  21387. }
  21388. _ACEOF
  21389. if ac_fn_c_try_link "$LINENO"; then :
  21390. eval "$as_ac_Lib=yes"
  21391. else
  21392. eval "$as_ac_Lib=no"
  21393. fi
  21394. rm -f core conftest.err conftest.$ac_objext \
  21395. conftest$ac_exeext conftest.$ac_ext
  21396. LIBS=$ac_check_lib_save_LIBS
  21397. fi
  21398. eval ac_res=\$$as_ac_Lib
  21399. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21400. $as_echo "$ac_res" >&6; }
  21401. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21402. AST_PRI_L2_PERSISTENCE_FOUND=yes
  21403. else
  21404. AST_PRI_L2_PERSISTENCE_FOUND=no
  21405. fi
  21406. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21407. fi
  21408. # now check for the header.
  21409. if test "${AST_PRI_L2_PERSISTENCE_FOUND}" = "yes"; then
  21410. PRI_L2_PERSISTENCE_LIB="${pbxlibdir} -lpri "
  21411. # if --with-PRI_L2_PERSISTENCE=DIR has been specified, use it.
  21412. if test "x${PRI_L2_PERSISTENCE_DIR}" != "x"; then
  21413. PRI_L2_PERSISTENCE_INCLUDE="-I${PRI_L2_PERSISTENCE_DIR}/include"
  21414. fi
  21415. PRI_L2_PERSISTENCE_INCLUDE="${PRI_L2_PERSISTENCE_INCLUDE} "
  21416. if test "xlibpri.h" = "x" ; then # no header, assume found
  21417. PRI_L2_PERSISTENCE_HEADER_FOUND="1"
  21418. else # check for the header
  21419. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21420. CPPFLAGS="${CPPFLAGS} ${PRI_L2_PERSISTENCE_INCLUDE}"
  21421. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21422. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21423. PRI_L2_PERSISTENCE_HEADER_FOUND=1
  21424. else
  21425. PRI_L2_PERSISTENCE_HEADER_FOUND=0
  21426. fi
  21427. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21428. fi
  21429. if test "x${PRI_L2_PERSISTENCE_HEADER_FOUND}" = "x0" ; then
  21430. PRI_L2_PERSISTENCE_LIB=""
  21431. PRI_L2_PERSISTENCE_INCLUDE=""
  21432. else
  21433. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21434. PRI_L2_PERSISTENCE_LIB=""
  21435. fi
  21436. PBX_PRI_L2_PERSISTENCE=1
  21437. cat >>confdefs.h <<_ACEOF
  21438. #define HAVE_PRI_L2_PERSISTENCE 1
  21439. _ACEOF
  21440. fi
  21441. fi
  21442. fi
  21443. if test "x${PBX_PRI_DATETIME_SEND}" != "x1" -a "${USE_PRI_DATETIME_SEND}" != "no"; then
  21444. pbxlibdir=""
  21445. # if --with-PRI_DATETIME_SEND=DIR has been specified, use it.
  21446. if test "x${PRI_DATETIME_SEND_DIR}" != "x"; then
  21447. if test -d ${PRI_DATETIME_SEND_DIR}/lib; then
  21448. pbxlibdir="-L${PRI_DATETIME_SEND_DIR}/lib"
  21449. else
  21450. pbxlibdir="-L${PRI_DATETIME_SEND_DIR}"
  21451. fi
  21452. fi
  21453. pbxfuncname="pri_date_time_send_option"
  21454. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21455. AST_PRI_DATETIME_SEND_FOUND=yes
  21456. else
  21457. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21458. CFLAGS="${CFLAGS} "
  21459. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21460. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21461. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21462. if eval \${$as_ac_Lib+:} false; then :
  21463. $as_echo_n "(cached) " >&6
  21464. else
  21465. ac_check_lib_save_LIBS=$LIBS
  21466. LIBS="-lpri ${pbxlibdir} $LIBS"
  21467. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21468. /* end confdefs.h. */
  21469. /* Override any GCC internal prototype to avoid an error.
  21470. Use char because int might match the return type of a GCC
  21471. builtin and then its argument prototype would still apply. */
  21472. #ifdef __cplusplus
  21473. extern "C"
  21474. #endif
  21475. char ${pbxfuncname} ();
  21476. int
  21477. main ()
  21478. {
  21479. return ${pbxfuncname} ();
  21480. ;
  21481. return 0;
  21482. }
  21483. _ACEOF
  21484. if ac_fn_c_try_link "$LINENO"; then :
  21485. eval "$as_ac_Lib=yes"
  21486. else
  21487. eval "$as_ac_Lib=no"
  21488. fi
  21489. rm -f core conftest.err conftest.$ac_objext \
  21490. conftest$ac_exeext conftest.$ac_ext
  21491. LIBS=$ac_check_lib_save_LIBS
  21492. fi
  21493. eval ac_res=\$$as_ac_Lib
  21494. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21495. $as_echo "$ac_res" >&6; }
  21496. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21497. AST_PRI_DATETIME_SEND_FOUND=yes
  21498. else
  21499. AST_PRI_DATETIME_SEND_FOUND=no
  21500. fi
  21501. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21502. fi
  21503. # now check for the header.
  21504. if test "${AST_PRI_DATETIME_SEND_FOUND}" = "yes"; then
  21505. PRI_DATETIME_SEND_LIB="${pbxlibdir} -lpri "
  21506. # if --with-PRI_DATETIME_SEND=DIR has been specified, use it.
  21507. if test "x${PRI_DATETIME_SEND_DIR}" != "x"; then
  21508. PRI_DATETIME_SEND_INCLUDE="-I${PRI_DATETIME_SEND_DIR}/include"
  21509. fi
  21510. PRI_DATETIME_SEND_INCLUDE="${PRI_DATETIME_SEND_INCLUDE} "
  21511. if test "xlibpri.h" = "x" ; then # no header, assume found
  21512. PRI_DATETIME_SEND_HEADER_FOUND="1"
  21513. else # check for the header
  21514. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21515. CPPFLAGS="${CPPFLAGS} ${PRI_DATETIME_SEND_INCLUDE}"
  21516. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21517. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21518. PRI_DATETIME_SEND_HEADER_FOUND=1
  21519. else
  21520. PRI_DATETIME_SEND_HEADER_FOUND=0
  21521. fi
  21522. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21523. fi
  21524. if test "x${PRI_DATETIME_SEND_HEADER_FOUND}" = "x0" ; then
  21525. PRI_DATETIME_SEND_LIB=""
  21526. PRI_DATETIME_SEND_INCLUDE=""
  21527. else
  21528. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21529. PRI_DATETIME_SEND_LIB=""
  21530. fi
  21531. PBX_PRI_DATETIME_SEND=1
  21532. cat >>confdefs.h <<_ACEOF
  21533. #define HAVE_PRI_DATETIME_SEND 1
  21534. _ACEOF
  21535. fi
  21536. fi
  21537. fi
  21538. if test "x${PBX_PRI_MWI_V2}" != "x1" -a "${USE_PRI_MWI_V2}" != "no"; then
  21539. pbxlibdir=""
  21540. # if --with-PRI_MWI_V2=DIR has been specified, use it.
  21541. if test "x${PRI_MWI_V2_DIR}" != "x"; then
  21542. if test -d ${PRI_MWI_V2_DIR}/lib; then
  21543. pbxlibdir="-L${PRI_MWI_V2_DIR}/lib"
  21544. else
  21545. pbxlibdir="-L${PRI_MWI_V2_DIR}"
  21546. fi
  21547. fi
  21548. pbxfuncname="pri_mwi_indicate_v2"
  21549. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21550. AST_PRI_MWI_V2_FOUND=yes
  21551. else
  21552. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21553. CFLAGS="${CFLAGS} "
  21554. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21555. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21556. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21557. if eval \${$as_ac_Lib+:} false; then :
  21558. $as_echo_n "(cached) " >&6
  21559. else
  21560. ac_check_lib_save_LIBS=$LIBS
  21561. LIBS="-lpri ${pbxlibdir} $LIBS"
  21562. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21563. /* end confdefs.h. */
  21564. /* Override any GCC internal prototype to avoid an error.
  21565. Use char because int might match the return type of a GCC
  21566. builtin and then its argument prototype would still apply. */
  21567. #ifdef __cplusplus
  21568. extern "C"
  21569. #endif
  21570. char ${pbxfuncname} ();
  21571. int
  21572. main ()
  21573. {
  21574. return ${pbxfuncname} ();
  21575. ;
  21576. return 0;
  21577. }
  21578. _ACEOF
  21579. if ac_fn_c_try_link "$LINENO"; then :
  21580. eval "$as_ac_Lib=yes"
  21581. else
  21582. eval "$as_ac_Lib=no"
  21583. fi
  21584. rm -f core conftest.err conftest.$ac_objext \
  21585. conftest$ac_exeext conftest.$ac_ext
  21586. LIBS=$ac_check_lib_save_LIBS
  21587. fi
  21588. eval ac_res=\$$as_ac_Lib
  21589. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21590. $as_echo "$ac_res" >&6; }
  21591. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21592. AST_PRI_MWI_V2_FOUND=yes
  21593. else
  21594. AST_PRI_MWI_V2_FOUND=no
  21595. fi
  21596. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21597. fi
  21598. # now check for the header.
  21599. if test "${AST_PRI_MWI_V2_FOUND}" = "yes"; then
  21600. PRI_MWI_V2_LIB="${pbxlibdir} -lpri "
  21601. # if --with-PRI_MWI_V2=DIR has been specified, use it.
  21602. if test "x${PRI_MWI_V2_DIR}" != "x"; then
  21603. PRI_MWI_V2_INCLUDE="-I${PRI_MWI_V2_DIR}/include"
  21604. fi
  21605. PRI_MWI_V2_INCLUDE="${PRI_MWI_V2_INCLUDE} "
  21606. if test "xlibpri.h" = "x" ; then # no header, assume found
  21607. PRI_MWI_V2_HEADER_FOUND="1"
  21608. else # check for the header
  21609. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21610. CPPFLAGS="${CPPFLAGS} ${PRI_MWI_V2_INCLUDE}"
  21611. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21612. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21613. PRI_MWI_V2_HEADER_FOUND=1
  21614. else
  21615. PRI_MWI_V2_HEADER_FOUND=0
  21616. fi
  21617. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21618. fi
  21619. if test "x${PRI_MWI_V2_HEADER_FOUND}" = "x0" ; then
  21620. PRI_MWI_V2_LIB=""
  21621. PRI_MWI_V2_INCLUDE=""
  21622. else
  21623. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21624. PRI_MWI_V2_LIB=""
  21625. fi
  21626. PBX_PRI_MWI_V2=1
  21627. cat >>confdefs.h <<_ACEOF
  21628. #define HAVE_PRI_MWI_V2 1
  21629. _ACEOF
  21630. fi
  21631. fi
  21632. fi
  21633. if test "x${PBX_PRI_DISPLAY_TEXT}" != "x1" -a "${USE_PRI_DISPLAY_TEXT}" != "no"; then
  21634. pbxlibdir=""
  21635. # if --with-PRI_DISPLAY_TEXT=DIR has been specified, use it.
  21636. if test "x${PRI_DISPLAY_TEXT_DIR}" != "x"; then
  21637. if test -d ${PRI_DISPLAY_TEXT_DIR}/lib; then
  21638. pbxlibdir="-L${PRI_DISPLAY_TEXT_DIR}/lib"
  21639. else
  21640. pbxlibdir="-L${PRI_DISPLAY_TEXT_DIR}"
  21641. fi
  21642. fi
  21643. pbxfuncname="pri_display_text"
  21644. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21645. AST_PRI_DISPLAY_TEXT_FOUND=yes
  21646. else
  21647. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21648. CFLAGS="${CFLAGS} "
  21649. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21650. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21651. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21652. if eval \${$as_ac_Lib+:} false; then :
  21653. $as_echo_n "(cached) " >&6
  21654. else
  21655. ac_check_lib_save_LIBS=$LIBS
  21656. LIBS="-lpri ${pbxlibdir} $LIBS"
  21657. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21658. /* end confdefs.h. */
  21659. /* Override any GCC internal prototype to avoid an error.
  21660. Use char because int might match the return type of a GCC
  21661. builtin and then its argument prototype would still apply. */
  21662. #ifdef __cplusplus
  21663. extern "C"
  21664. #endif
  21665. char ${pbxfuncname} ();
  21666. int
  21667. main ()
  21668. {
  21669. return ${pbxfuncname} ();
  21670. ;
  21671. return 0;
  21672. }
  21673. _ACEOF
  21674. if ac_fn_c_try_link "$LINENO"; then :
  21675. eval "$as_ac_Lib=yes"
  21676. else
  21677. eval "$as_ac_Lib=no"
  21678. fi
  21679. rm -f core conftest.err conftest.$ac_objext \
  21680. conftest$ac_exeext conftest.$ac_ext
  21681. LIBS=$ac_check_lib_save_LIBS
  21682. fi
  21683. eval ac_res=\$$as_ac_Lib
  21684. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21685. $as_echo "$ac_res" >&6; }
  21686. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21687. AST_PRI_DISPLAY_TEXT_FOUND=yes
  21688. else
  21689. AST_PRI_DISPLAY_TEXT_FOUND=no
  21690. fi
  21691. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21692. fi
  21693. # now check for the header.
  21694. if test "${AST_PRI_DISPLAY_TEXT_FOUND}" = "yes"; then
  21695. PRI_DISPLAY_TEXT_LIB="${pbxlibdir} -lpri "
  21696. # if --with-PRI_DISPLAY_TEXT=DIR has been specified, use it.
  21697. if test "x${PRI_DISPLAY_TEXT_DIR}" != "x"; then
  21698. PRI_DISPLAY_TEXT_INCLUDE="-I${PRI_DISPLAY_TEXT_DIR}/include"
  21699. fi
  21700. PRI_DISPLAY_TEXT_INCLUDE="${PRI_DISPLAY_TEXT_INCLUDE} "
  21701. if test "xlibpri.h" = "x" ; then # no header, assume found
  21702. PRI_DISPLAY_TEXT_HEADER_FOUND="1"
  21703. else # check for the header
  21704. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21705. CPPFLAGS="${CPPFLAGS} ${PRI_DISPLAY_TEXT_INCLUDE}"
  21706. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21707. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21708. PRI_DISPLAY_TEXT_HEADER_FOUND=1
  21709. else
  21710. PRI_DISPLAY_TEXT_HEADER_FOUND=0
  21711. fi
  21712. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21713. fi
  21714. if test "x${PRI_DISPLAY_TEXT_HEADER_FOUND}" = "x0" ; then
  21715. PRI_DISPLAY_TEXT_LIB=""
  21716. PRI_DISPLAY_TEXT_INCLUDE=""
  21717. else
  21718. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21719. PRI_DISPLAY_TEXT_LIB=""
  21720. fi
  21721. PBX_PRI_DISPLAY_TEXT=1
  21722. cat >>confdefs.h <<_ACEOF
  21723. #define HAVE_PRI_DISPLAY_TEXT 1
  21724. _ACEOF
  21725. fi
  21726. fi
  21727. fi
  21728. if test "x${PBX_PRI_MWI}" != "x1" -a "${USE_PRI_MWI}" != "no"; then
  21729. pbxlibdir=""
  21730. # if --with-PRI_MWI=DIR has been specified, use it.
  21731. if test "x${PRI_MWI_DIR}" != "x"; then
  21732. if test -d ${PRI_MWI_DIR}/lib; then
  21733. pbxlibdir="-L${PRI_MWI_DIR}/lib"
  21734. else
  21735. pbxlibdir="-L${PRI_MWI_DIR}"
  21736. fi
  21737. fi
  21738. pbxfuncname="pri_mwi_indicate"
  21739. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21740. AST_PRI_MWI_FOUND=yes
  21741. else
  21742. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21743. CFLAGS="${CFLAGS} "
  21744. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21745. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21746. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21747. if eval \${$as_ac_Lib+:} false; then :
  21748. $as_echo_n "(cached) " >&6
  21749. else
  21750. ac_check_lib_save_LIBS=$LIBS
  21751. LIBS="-lpri ${pbxlibdir} $LIBS"
  21752. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21753. /* end confdefs.h. */
  21754. /* Override any GCC internal prototype to avoid an error.
  21755. Use char because int might match the return type of a GCC
  21756. builtin and then its argument prototype would still apply. */
  21757. #ifdef __cplusplus
  21758. extern "C"
  21759. #endif
  21760. char ${pbxfuncname} ();
  21761. int
  21762. main ()
  21763. {
  21764. return ${pbxfuncname} ();
  21765. ;
  21766. return 0;
  21767. }
  21768. _ACEOF
  21769. if ac_fn_c_try_link "$LINENO"; then :
  21770. eval "$as_ac_Lib=yes"
  21771. else
  21772. eval "$as_ac_Lib=no"
  21773. fi
  21774. rm -f core conftest.err conftest.$ac_objext \
  21775. conftest$ac_exeext conftest.$ac_ext
  21776. LIBS=$ac_check_lib_save_LIBS
  21777. fi
  21778. eval ac_res=\$$as_ac_Lib
  21779. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21780. $as_echo "$ac_res" >&6; }
  21781. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21782. AST_PRI_MWI_FOUND=yes
  21783. else
  21784. AST_PRI_MWI_FOUND=no
  21785. fi
  21786. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21787. fi
  21788. # now check for the header.
  21789. if test "${AST_PRI_MWI_FOUND}" = "yes"; then
  21790. PRI_MWI_LIB="${pbxlibdir} -lpri "
  21791. # if --with-PRI_MWI=DIR has been specified, use it.
  21792. if test "x${PRI_MWI_DIR}" != "x"; then
  21793. PRI_MWI_INCLUDE="-I${PRI_MWI_DIR}/include"
  21794. fi
  21795. PRI_MWI_INCLUDE="${PRI_MWI_INCLUDE} "
  21796. if test "xlibpri.h" = "x" ; then # no header, assume found
  21797. PRI_MWI_HEADER_FOUND="1"
  21798. else # check for the header
  21799. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21800. CPPFLAGS="${CPPFLAGS} ${PRI_MWI_INCLUDE}"
  21801. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21802. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21803. PRI_MWI_HEADER_FOUND=1
  21804. else
  21805. PRI_MWI_HEADER_FOUND=0
  21806. fi
  21807. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21808. fi
  21809. if test "x${PRI_MWI_HEADER_FOUND}" = "x0" ; then
  21810. PRI_MWI_LIB=""
  21811. PRI_MWI_INCLUDE=""
  21812. else
  21813. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21814. PRI_MWI_LIB=""
  21815. fi
  21816. PBX_PRI_MWI=1
  21817. cat >>confdefs.h <<_ACEOF
  21818. #define HAVE_PRI_MWI 1
  21819. _ACEOF
  21820. fi
  21821. fi
  21822. fi
  21823. if test "x${PBX_PRI_MCID}" != "x1" -a "${USE_PRI_MCID}" != "no"; then
  21824. pbxlibdir=""
  21825. # if --with-PRI_MCID=DIR has been specified, use it.
  21826. if test "x${PRI_MCID_DIR}" != "x"; then
  21827. if test -d ${PRI_MCID_DIR}/lib; then
  21828. pbxlibdir="-L${PRI_MCID_DIR}/lib"
  21829. else
  21830. pbxlibdir="-L${PRI_MCID_DIR}"
  21831. fi
  21832. fi
  21833. pbxfuncname="pri_mcid_enable"
  21834. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21835. AST_PRI_MCID_FOUND=yes
  21836. else
  21837. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21838. CFLAGS="${CFLAGS} "
  21839. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21840. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21841. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21842. if eval \${$as_ac_Lib+:} false; then :
  21843. $as_echo_n "(cached) " >&6
  21844. else
  21845. ac_check_lib_save_LIBS=$LIBS
  21846. LIBS="-lpri ${pbxlibdir} $LIBS"
  21847. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21848. /* end confdefs.h. */
  21849. /* Override any GCC internal prototype to avoid an error.
  21850. Use char because int might match the return type of a GCC
  21851. builtin and then its argument prototype would still apply. */
  21852. #ifdef __cplusplus
  21853. extern "C"
  21854. #endif
  21855. char ${pbxfuncname} ();
  21856. int
  21857. main ()
  21858. {
  21859. return ${pbxfuncname} ();
  21860. ;
  21861. return 0;
  21862. }
  21863. _ACEOF
  21864. if ac_fn_c_try_link "$LINENO"; then :
  21865. eval "$as_ac_Lib=yes"
  21866. else
  21867. eval "$as_ac_Lib=no"
  21868. fi
  21869. rm -f core conftest.err conftest.$ac_objext \
  21870. conftest$ac_exeext conftest.$ac_ext
  21871. LIBS=$ac_check_lib_save_LIBS
  21872. fi
  21873. eval ac_res=\$$as_ac_Lib
  21874. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21875. $as_echo "$ac_res" >&6; }
  21876. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21877. AST_PRI_MCID_FOUND=yes
  21878. else
  21879. AST_PRI_MCID_FOUND=no
  21880. fi
  21881. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21882. fi
  21883. # now check for the header.
  21884. if test "${AST_PRI_MCID_FOUND}" = "yes"; then
  21885. PRI_MCID_LIB="${pbxlibdir} -lpri "
  21886. # if --with-PRI_MCID=DIR has been specified, use it.
  21887. if test "x${PRI_MCID_DIR}" != "x"; then
  21888. PRI_MCID_INCLUDE="-I${PRI_MCID_DIR}/include"
  21889. fi
  21890. PRI_MCID_INCLUDE="${PRI_MCID_INCLUDE} "
  21891. if test "xlibpri.h" = "x" ; then # no header, assume found
  21892. PRI_MCID_HEADER_FOUND="1"
  21893. else # check for the header
  21894. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21895. CPPFLAGS="${CPPFLAGS} ${PRI_MCID_INCLUDE}"
  21896. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21897. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21898. PRI_MCID_HEADER_FOUND=1
  21899. else
  21900. PRI_MCID_HEADER_FOUND=0
  21901. fi
  21902. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21903. fi
  21904. if test "x${PRI_MCID_HEADER_FOUND}" = "x0" ; then
  21905. PRI_MCID_LIB=""
  21906. PRI_MCID_INCLUDE=""
  21907. else
  21908. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  21909. PRI_MCID_LIB=""
  21910. fi
  21911. PBX_PRI_MCID=1
  21912. cat >>confdefs.h <<_ACEOF
  21913. #define HAVE_PRI_MCID 1
  21914. _ACEOF
  21915. fi
  21916. fi
  21917. fi
  21918. if test "x${PBX_PRI_CALL_WAITING}" != "x1" -a "${USE_PRI_CALL_WAITING}" != "no"; then
  21919. pbxlibdir=""
  21920. # if --with-PRI_CALL_WAITING=DIR has been specified, use it.
  21921. if test "x${PRI_CALL_WAITING_DIR}" != "x"; then
  21922. if test -d ${PRI_CALL_WAITING_DIR}/lib; then
  21923. pbxlibdir="-L${PRI_CALL_WAITING_DIR}/lib"
  21924. else
  21925. pbxlibdir="-L${PRI_CALL_WAITING_DIR}"
  21926. fi
  21927. fi
  21928. pbxfuncname="pri_connect_ack_enable"
  21929. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  21930. AST_PRI_CALL_WAITING_FOUND=yes
  21931. else
  21932. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  21933. CFLAGS="${CFLAGS} "
  21934. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  21935. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  21936. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  21937. if eval \${$as_ac_Lib+:} false; then :
  21938. $as_echo_n "(cached) " >&6
  21939. else
  21940. ac_check_lib_save_LIBS=$LIBS
  21941. LIBS="-lpri ${pbxlibdir} $LIBS"
  21942. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  21943. /* end confdefs.h. */
  21944. /* Override any GCC internal prototype to avoid an error.
  21945. Use char because int might match the return type of a GCC
  21946. builtin and then its argument prototype would still apply. */
  21947. #ifdef __cplusplus
  21948. extern "C"
  21949. #endif
  21950. char ${pbxfuncname} ();
  21951. int
  21952. main ()
  21953. {
  21954. return ${pbxfuncname} ();
  21955. ;
  21956. return 0;
  21957. }
  21958. _ACEOF
  21959. if ac_fn_c_try_link "$LINENO"; then :
  21960. eval "$as_ac_Lib=yes"
  21961. else
  21962. eval "$as_ac_Lib=no"
  21963. fi
  21964. rm -f core conftest.err conftest.$ac_objext \
  21965. conftest$ac_exeext conftest.$ac_ext
  21966. LIBS=$ac_check_lib_save_LIBS
  21967. fi
  21968. eval ac_res=\$$as_ac_Lib
  21969. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  21970. $as_echo "$ac_res" >&6; }
  21971. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  21972. AST_PRI_CALL_WAITING_FOUND=yes
  21973. else
  21974. AST_PRI_CALL_WAITING_FOUND=no
  21975. fi
  21976. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  21977. fi
  21978. # now check for the header.
  21979. if test "${AST_PRI_CALL_WAITING_FOUND}" = "yes"; then
  21980. PRI_CALL_WAITING_LIB="${pbxlibdir} -lpri "
  21981. # if --with-PRI_CALL_WAITING=DIR has been specified, use it.
  21982. if test "x${PRI_CALL_WAITING_DIR}" != "x"; then
  21983. PRI_CALL_WAITING_INCLUDE="-I${PRI_CALL_WAITING_DIR}/include"
  21984. fi
  21985. PRI_CALL_WAITING_INCLUDE="${PRI_CALL_WAITING_INCLUDE} "
  21986. if test "xlibpri.h" = "x" ; then # no header, assume found
  21987. PRI_CALL_WAITING_HEADER_FOUND="1"
  21988. else # check for the header
  21989. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  21990. CPPFLAGS="${CPPFLAGS} ${PRI_CALL_WAITING_INCLUDE}"
  21991. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  21992. if test "x$ac_cv_header_libpri_h" = xyes; then :
  21993. PRI_CALL_WAITING_HEADER_FOUND=1
  21994. else
  21995. PRI_CALL_WAITING_HEADER_FOUND=0
  21996. fi
  21997. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  21998. fi
  21999. if test "x${PRI_CALL_WAITING_HEADER_FOUND}" = "x0" ; then
  22000. PRI_CALL_WAITING_LIB=""
  22001. PRI_CALL_WAITING_INCLUDE=""
  22002. else
  22003. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22004. PRI_CALL_WAITING_LIB=""
  22005. fi
  22006. PBX_PRI_CALL_WAITING=1
  22007. cat >>confdefs.h <<_ACEOF
  22008. #define HAVE_PRI_CALL_WAITING 1
  22009. _ACEOF
  22010. fi
  22011. fi
  22012. fi
  22013. if test "x${PBX_PRI_AOC_EVENTS}" != "x1" -a "${USE_PRI_AOC_EVENTS}" != "no"; then
  22014. pbxlibdir=""
  22015. # if --with-PRI_AOC_EVENTS=DIR has been specified, use it.
  22016. if test "x${PRI_AOC_EVENTS_DIR}" != "x"; then
  22017. if test -d ${PRI_AOC_EVENTS_DIR}/lib; then
  22018. pbxlibdir="-L${PRI_AOC_EVENTS_DIR}/lib"
  22019. else
  22020. pbxlibdir="-L${PRI_AOC_EVENTS_DIR}"
  22021. fi
  22022. fi
  22023. pbxfuncname="pri_aoc_events_enable"
  22024. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22025. AST_PRI_AOC_EVENTS_FOUND=yes
  22026. else
  22027. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22028. CFLAGS="${CFLAGS} "
  22029. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22030. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22031. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22032. if eval \${$as_ac_Lib+:} false; then :
  22033. $as_echo_n "(cached) " >&6
  22034. else
  22035. ac_check_lib_save_LIBS=$LIBS
  22036. LIBS="-lpri ${pbxlibdir} $LIBS"
  22037. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22038. /* end confdefs.h. */
  22039. /* Override any GCC internal prototype to avoid an error.
  22040. Use char because int might match the return type of a GCC
  22041. builtin and then its argument prototype would still apply. */
  22042. #ifdef __cplusplus
  22043. extern "C"
  22044. #endif
  22045. char ${pbxfuncname} ();
  22046. int
  22047. main ()
  22048. {
  22049. return ${pbxfuncname} ();
  22050. ;
  22051. return 0;
  22052. }
  22053. _ACEOF
  22054. if ac_fn_c_try_link "$LINENO"; then :
  22055. eval "$as_ac_Lib=yes"
  22056. else
  22057. eval "$as_ac_Lib=no"
  22058. fi
  22059. rm -f core conftest.err conftest.$ac_objext \
  22060. conftest$ac_exeext conftest.$ac_ext
  22061. LIBS=$ac_check_lib_save_LIBS
  22062. fi
  22063. eval ac_res=\$$as_ac_Lib
  22064. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22065. $as_echo "$ac_res" >&6; }
  22066. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22067. AST_PRI_AOC_EVENTS_FOUND=yes
  22068. else
  22069. AST_PRI_AOC_EVENTS_FOUND=no
  22070. fi
  22071. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22072. fi
  22073. # now check for the header.
  22074. if test "${AST_PRI_AOC_EVENTS_FOUND}" = "yes"; then
  22075. PRI_AOC_EVENTS_LIB="${pbxlibdir} -lpri "
  22076. # if --with-PRI_AOC_EVENTS=DIR has been specified, use it.
  22077. if test "x${PRI_AOC_EVENTS_DIR}" != "x"; then
  22078. PRI_AOC_EVENTS_INCLUDE="-I${PRI_AOC_EVENTS_DIR}/include"
  22079. fi
  22080. PRI_AOC_EVENTS_INCLUDE="${PRI_AOC_EVENTS_INCLUDE} "
  22081. if test "xlibpri.h" = "x" ; then # no header, assume found
  22082. PRI_AOC_EVENTS_HEADER_FOUND="1"
  22083. else # check for the header
  22084. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22085. CPPFLAGS="${CPPFLAGS} ${PRI_AOC_EVENTS_INCLUDE}"
  22086. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22087. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22088. PRI_AOC_EVENTS_HEADER_FOUND=1
  22089. else
  22090. PRI_AOC_EVENTS_HEADER_FOUND=0
  22091. fi
  22092. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22093. fi
  22094. if test "x${PRI_AOC_EVENTS_HEADER_FOUND}" = "x0" ; then
  22095. PRI_AOC_EVENTS_LIB=""
  22096. PRI_AOC_EVENTS_INCLUDE=""
  22097. else
  22098. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22099. PRI_AOC_EVENTS_LIB=""
  22100. fi
  22101. PBX_PRI_AOC_EVENTS=1
  22102. cat >>confdefs.h <<_ACEOF
  22103. #define HAVE_PRI_AOC_EVENTS 1
  22104. _ACEOF
  22105. fi
  22106. fi
  22107. fi
  22108. if test "x${PBX_PRI_TRANSFER}" != "x1" -a "${USE_PRI_TRANSFER}" != "no"; then
  22109. pbxlibdir=""
  22110. # if --with-PRI_TRANSFER=DIR has been specified, use it.
  22111. if test "x${PRI_TRANSFER_DIR}" != "x"; then
  22112. if test -d ${PRI_TRANSFER_DIR}/lib; then
  22113. pbxlibdir="-L${PRI_TRANSFER_DIR}/lib"
  22114. else
  22115. pbxlibdir="-L${PRI_TRANSFER_DIR}"
  22116. fi
  22117. fi
  22118. pbxfuncname="pri_transfer_enable"
  22119. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22120. AST_PRI_TRANSFER_FOUND=yes
  22121. else
  22122. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22123. CFLAGS="${CFLAGS} "
  22124. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22125. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22126. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22127. if eval \${$as_ac_Lib+:} false; then :
  22128. $as_echo_n "(cached) " >&6
  22129. else
  22130. ac_check_lib_save_LIBS=$LIBS
  22131. LIBS="-lpri ${pbxlibdir} $LIBS"
  22132. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22133. /* end confdefs.h. */
  22134. /* Override any GCC internal prototype to avoid an error.
  22135. Use char because int might match the return type of a GCC
  22136. builtin and then its argument prototype would still apply. */
  22137. #ifdef __cplusplus
  22138. extern "C"
  22139. #endif
  22140. char ${pbxfuncname} ();
  22141. int
  22142. main ()
  22143. {
  22144. return ${pbxfuncname} ();
  22145. ;
  22146. return 0;
  22147. }
  22148. _ACEOF
  22149. if ac_fn_c_try_link "$LINENO"; then :
  22150. eval "$as_ac_Lib=yes"
  22151. else
  22152. eval "$as_ac_Lib=no"
  22153. fi
  22154. rm -f core conftest.err conftest.$ac_objext \
  22155. conftest$ac_exeext conftest.$ac_ext
  22156. LIBS=$ac_check_lib_save_LIBS
  22157. fi
  22158. eval ac_res=\$$as_ac_Lib
  22159. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22160. $as_echo "$ac_res" >&6; }
  22161. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22162. AST_PRI_TRANSFER_FOUND=yes
  22163. else
  22164. AST_PRI_TRANSFER_FOUND=no
  22165. fi
  22166. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22167. fi
  22168. # now check for the header.
  22169. if test "${AST_PRI_TRANSFER_FOUND}" = "yes"; then
  22170. PRI_TRANSFER_LIB="${pbxlibdir} -lpri "
  22171. # if --with-PRI_TRANSFER=DIR has been specified, use it.
  22172. if test "x${PRI_TRANSFER_DIR}" != "x"; then
  22173. PRI_TRANSFER_INCLUDE="-I${PRI_TRANSFER_DIR}/include"
  22174. fi
  22175. PRI_TRANSFER_INCLUDE="${PRI_TRANSFER_INCLUDE} "
  22176. if test "xlibpri.h" = "x" ; then # no header, assume found
  22177. PRI_TRANSFER_HEADER_FOUND="1"
  22178. else # check for the header
  22179. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22180. CPPFLAGS="${CPPFLAGS} ${PRI_TRANSFER_INCLUDE}"
  22181. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22182. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22183. PRI_TRANSFER_HEADER_FOUND=1
  22184. else
  22185. PRI_TRANSFER_HEADER_FOUND=0
  22186. fi
  22187. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22188. fi
  22189. if test "x${PRI_TRANSFER_HEADER_FOUND}" = "x0" ; then
  22190. PRI_TRANSFER_LIB=""
  22191. PRI_TRANSFER_INCLUDE=""
  22192. else
  22193. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22194. PRI_TRANSFER_LIB=""
  22195. fi
  22196. PBX_PRI_TRANSFER=1
  22197. cat >>confdefs.h <<_ACEOF
  22198. #define HAVE_PRI_TRANSFER 1
  22199. _ACEOF
  22200. fi
  22201. fi
  22202. fi
  22203. if test "x${PBX_PRI_CCSS}" != "x1" -a "${USE_PRI_CCSS}" != "no"; then
  22204. pbxlibdir=""
  22205. # if --with-PRI_CCSS=DIR has been specified, use it.
  22206. if test "x${PRI_CCSS_DIR}" != "x"; then
  22207. if test -d ${PRI_CCSS_DIR}/lib; then
  22208. pbxlibdir="-L${PRI_CCSS_DIR}/lib"
  22209. else
  22210. pbxlibdir="-L${PRI_CCSS_DIR}"
  22211. fi
  22212. fi
  22213. pbxfuncname="pri_cc_enable"
  22214. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22215. AST_PRI_CCSS_FOUND=yes
  22216. else
  22217. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22218. CFLAGS="${CFLAGS} "
  22219. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22220. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22221. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22222. if eval \${$as_ac_Lib+:} false; then :
  22223. $as_echo_n "(cached) " >&6
  22224. else
  22225. ac_check_lib_save_LIBS=$LIBS
  22226. LIBS="-lpri ${pbxlibdir} $LIBS"
  22227. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22228. /* end confdefs.h. */
  22229. /* Override any GCC internal prototype to avoid an error.
  22230. Use char because int might match the return type of a GCC
  22231. builtin and then its argument prototype would still apply. */
  22232. #ifdef __cplusplus
  22233. extern "C"
  22234. #endif
  22235. char ${pbxfuncname} ();
  22236. int
  22237. main ()
  22238. {
  22239. return ${pbxfuncname} ();
  22240. ;
  22241. return 0;
  22242. }
  22243. _ACEOF
  22244. if ac_fn_c_try_link "$LINENO"; then :
  22245. eval "$as_ac_Lib=yes"
  22246. else
  22247. eval "$as_ac_Lib=no"
  22248. fi
  22249. rm -f core conftest.err conftest.$ac_objext \
  22250. conftest$ac_exeext conftest.$ac_ext
  22251. LIBS=$ac_check_lib_save_LIBS
  22252. fi
  22253. eval ac_res=\$$as_ac_Lib
  22254. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22255. $as_echo "$ac_res" >&6; }
  22256. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22257. AST_PRI_CCSS_FOUND=yes
  22258. else
  22259. AST_PRI_CCSS_FOUND=no
  22260. fi
  22261. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22262. fi
  22263. # now check for the header.
  22264. if test "${AST_PRI_CCSS_FOUND}" = "yes"; then
  22265. PRI_CCSS_LIB="${pbxlibdir} -lpri "
  22266. # if --with-PRI_CCSS=DIR has been specified, use it.
  22267. if test "x${PRI_CCSS_DIR}" != "x"; then
  22268. PRI_CCSS_INCLUDE="-I${PRI_CCSS_DIR}/include"
  22269. fi
  22270. PRI_CCSS_INCLUDE="${PRI_CCSS_INCLUDE} "
  22271. if test "xlibpri.h" = "x" ; then # no header, assume found
  22272. PRI_CCSS_HEADER_FOUND="1"
  22273. else # check for the header
  22274. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22275. CPPFLAGS="${CPPFLAGS} ${PRI_CCSS_INCLUDE}"
  22276. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22277. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22278. PRI_CCSS_HEADER_FOUND=1
  22279. else
  22280. PRI_CCSS_HEADER_FOUND=0
  22281. fi
  22282. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22283. fi
  22284. if test "x${PRI_CCSS_HEADER_FOUND}" = "x0" ; then
  22285. PRI_CCSS_LIB=""
  22286. PRI_CCSS_INCLUDE=""
  22287. else
  22288. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22289. PRI_CCSS_LIB=""
  22290. fi
  22291. PBX_PRI_CCSS=1
  22292. cat >>confdefs.h <<_ACEOF
  22293. #define HAVE_PRI_CCSS 1
  22294. _ACEOF
  22295. fi
  22296. fi
  22297. fi
  22298. if test "x${PBX_PRI_HANGUP_FIX}" != "x1" -a "${USE_PRI_HANGUP_FIX}" != "no"; then
  22299. pbxlibdir=""
  22300. # if --with-PRI_HANGUP_FIX=DIR has been specified, use it.
  22301. if test "x${PRI_HANGUP_FIX_DIR}" != "x"; then
  22302. if test -d ${PRI_HANGUP_FIX_DIR}/lib; then
  22303. pbxlibdir="-L${PRI_HANGUP_FIX_DIR}/lib"
  22304. else
  22305. pbxlibdir="-L${PRI_HANGUP_FIX_DIR}"
  22306. fi
  22307. fi
  22308. pbxfuncname="pri_hangup_fix_enable"
  22309. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22310. AST_PRI_HANGUP_FIX_FOUND=yes
  22311. else
  22312. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22313. CFLAGS="${CFLAGS} "
  22314. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22315. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22316. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22317. if eval \${$as_ac_Lib+:} false; then :
  22318. $as_echo_n "(cached) " >&6
  22319. else
  22320. ac_check_lib_save_LIBS=$LIBS
  22321. LIBS="-lpri ${pbxlibdir} $LIBS"
  22322. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22323. /* end confdefs.h. */
  22324. /* Override any GCC internal prototype to avoid an error.
  22325. Use char because int might match the return type of a GCC
  22326. builtin and then its argument prototype would still apply. */
  22327. #ifdef __cplusplus
  22328. extern "C"
  22329. #endif
  22330. char ${pbxfuncname} ();
  22331. int
  22332. main ()
  22333. {
  22334. return ${pbxfuncname} ();
  22335. ;
  22336. return 0;
  22337. }
  22338. _ACEOF
  22339. if ac_fn_c_try_link "$LINENO"; then :
  22340. eval "$as_ac_Lib=yes"
  22341. else
  22342. eval "$as_ac_Lib=no"
  22343. fi
  22344. rm -f core conftest.err conftest.$ac_objext \
  22345. conftest$ac_exeext conftest.$ac_ext
  22346. LIBS=$ac_check_lib_save_LIBS
  22347. fi
  22348. eval ac_res=\$$as_ac_Lib
  22349. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22350. $as_echo "$ac_res" >&6; }
  22351. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22352. AST_PRI_HANGUP_FIX_FOUND=yes
  22353. else
  22354. AST_PRI_HANGUP_FIX_FOUND=no
  22355. fi
  22356. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22357. fi
  22358. # now check for the header.
  22359. if test "${AST_PRI_HANGUP_FIX_FOUND}" = "yes"; then
  22360. PRI_HANGUP_FIX_LIB="${pbxlibdir} -lpri "
  22361. # if --with-PRI_HANGUP_FIX=DIR has been specified, use it.
  22362. if test "x${PRI_HANGUP_FIX_DIR}" != "x"; then
  22363. PRI_HANGUP_FIX_INCLUDE="-I${PRI_HANGUP_FIX_DIR}/include"
  22364. fi
  22365. PRI_HANGUP_FIX_INCLUDE="${PRI_HANGUP_FIX_INCLUDE} "
  22366. if test "xlibpri.h" = "x" ; then # no header, assume found
  22367. PRI_HANGUP_FIX_HEADER_FOUND="1"
  22368. else # check for the header
  22369. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22370. CPPFLAGS="${CPPFLAGS} ${PRI_HANGUP_FIX_INCLUDE}"
  22371. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22372. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22373. PRI_HANGUP_FIX_HEADER_FOUND=1
  22374. else
  22375. PRI_HANGUP_FIX_HEADER_FOUND=0
  22376. fi
  22377. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22378. fi
  22379. if test "x${PRI_HANGUP_FIX_HEADER_FOUND}" = "x0" ; then
  22380. PRI_HANGUP_FIX_LIB=""
  22381. PRI_HANGUP_FIX_INCLUDE=""
  22382. else
  22383. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22384. PRI_HANGUP_FIX_LIB=""
  22385. fi
  22386. PBX_PRI_HANGUP_FIX=1
  22387. cat >>confdefs.h <<_ACEOF
  22388. #define HAVE_PRI_HANGUP_FIX 1
  22389. _ACEOF
  22390. fi
  22391. fi
  22392. fi
  22393. if test "x${PBX_PRI_SUBADDR}" != "x1" -a "${USE_PRI_SUBADDR}" != "no"; then
  22394. pbxlibdir=""
  22395. # if --with-PRI_SUBADDR=DIR has been specified, use it.
  22396. if test "x${PRI_SUBADDR_DIR}" != "x"; then
  22397. if test -d ${PRI_SUBADDR_DIR}/lib; then
  22398. pbxlibdir="-L${PRI_SUBADDR_DIR}/lib"
  22399. else
  22400. pbxlibdir="-L${PRI_SUBADDR_DIR}"
  22401. fi
  22402. fi
  22403. pbxfuncname="pri_sr_set_called_subaddress"
  22404. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22405. AST_PRI_SUBADDR_FOUND=yes
  22406. else
  22407. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22408. CFLAGS="${CFLAGS} "
  22409. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22410. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22411. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22412. if eval \${$as_ac_Lib+:} false; then :
  22413. $as_echo_n "(cached) " >&6
  22414. else
  22415. ac_check_lib_save_LIBS=$LIBS
  22416. LIBS="-lpri ${pbxlibdir} $LIBS"
  22417. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22418. /* end confdefs.h. */
  22419. /* Override any GCC internal prototype to avoid an error.
  22420. Use char because int might match the return type of a GCC
  22421. builtin and then its argument prototype would still apply. */
  22422. #ifdef __cplusplus
  22423. extern "C"
  22424. #endif
  22425. char ${pbxfuncname} ();
  22426. int
  22427. main ()
  22428. {
  22429. return ${pbxfuncname} ();
  22430. ;
  22431. return 0;
  22432. }
  22433. _ACEOF
  22434. if ac_fn_c_try_link "$LINENO"; then :
  22435. eval "$as_ac_Lib=yes"
  22436. else
  22437. eval "$as_ac_Lib=no"
  22438. fi
  22439. rm -f core conftest.err conftest.$ac_objext \
  22440. conftest$ac_exeext conftest.$ac_ext
  22441. LIBS=$ac_check_lib_save_LIBS
  22442. fi
  22443. eval ac_res=\$$as_ac_Lib
  22444. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22445. $as_echo "$ac_res" >&6; }
  22446. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22447. AST_PRI_SUBADDR_FOUND=yes
  22448. else
  22449. AST_PRI_SUBADDR_FOUND=no
  22450. fi
  22451. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22452. fi
  22453. # now check for the header.
  22454. if test "${AST_PRI_SUBADDR_FOUND}" = "yes"; then
  22455. PRI_SUBADDR_LIB="${pbxlibdir} -lpri "
  22456. # if --with-PRI_SUBADDR=DIR has been specified, use it.
  22457. if test "x${PRI_SUBADDR_DIR}" != "x"; then
  22458. PRI_SUBADDR_INCLUDE="-I${PRI_SUBADDR_DIR}/include"
  22459. fi
  22460. PRI_SUBADDR_INCLUDE="${PRI_SUBADDR_INCLUDE} "
  22461. if test "xlibpri.h" = "x" ; then # no header, assume found
  22462. PRI_SUBADDR_HEADER_FOUND="1"
  22463. else # check for the header
  22464. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22465. CPPFLAGS="${CPPFLAGS} ${PRI_SUBADDR_INCLUDE}"
  22466. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22467. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22468. PRI_SUBADDR_HEADER_FOUND=1
  22469. else
  22470. PRI_SUBADDR_HEADER_FOUND=0
  22471. fi
  22472. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22473. fi
  22474. if test "x${PRI_SUBADDR_HEADER_FOUND}" = "x0" ; then
  22475. PRI_SUBADDR_LIB=""
  22476. PRI_SUBADDR_INCLUDE=""
  22477. else
  22478. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22479. PRI_SUBADDR_LIB=""
  22480. fi
  22481. PBX_PRI_SUBADDR=1
  22482. cat >>confdefs.h <<_ACEOF
  22483. #define HAVE_PRI_SUBADDR 1
  22484. _ACEOF
  22485. fi
  22486. fi
  22487. fi
  22488. if test "x${PBX_PRI_CALL_HOLD}" != "x1" -a "${USE_PRI_CALL_HOLD}" != "no"; then
  22489. pbxlibdir=""
  22490. # if --with-PRI_CALL_HOLD=DIR has been specified, use it.
  22491. if test "x${PRI_CALL_HOLD_DIR}" != "x"; then
  22492. if test -d ${PRI_CALL_HOLD_DIR}/lib; then
  22493. pbxlibdir="-L${PRI_CALL_HOLD_DIR}/lib"
  22494. else
  22495. pbxlibdir="-L${PRI_CALL_HOLD_DIR}"
  22496. fi
  22497. fi
  22498. pbxfuncname="pri_hold_enable"
  22499. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22500. AST_PRI_CALL_HOLD_FOUND=yes
  22501. else
  22502. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22503. CFLAGS="${CFLAGS} "
  22504. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22505. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22506. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22507. if eval \${$as_ac_Lib+:} false; then :
  22508. $as_echo_n "(cached) " >&6
  22509. else
  22510. ac_check_lib_save_LIBS=$LIBS
  22511. LIBS="-lpri ${pbxlibdir} $LIBS"
  22512. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22513. /* end confdefs.h. */
  22514. /* Override any GCC internal prototype to avoid an error.
  22515. Use char because int might match the return type of a GCC
  22516. builtin and then its argument prototype would still apply. */
  22517. #ifdef __cplusplus
  22518. extern "C"
  22519. #endif
  22520. char ${pbxfuncname} ();
  22521. int
  22522. main ()
  22523. {
  22524. return ${pbxfuncname} ();
  22525. ;
  22526. return 0;
  22527. }
  22528. _ACEOF
  22529. if ac_fn_c_try_link "$LINENO"; then :
  22530. eval "$as_ac_Lib=yes"
  22531. else
  22532. eval "$as_ac_Lib=no"
  22533. fi
  22534. rm -f core conftest.err conftest.$ac_objext \
  22535. conftest$ac_exeext conftest.$ac_ext
  22536. LIBS=$ac_check_lib_save_LIBS
  22537. fi
  22538. eval ac_res=\$$as_ac_Lib
  22539. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22540. $as_echo "$ac_res" >&6; }
  22541. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22542. AST_PRI_CALL_HOLD_FOUND=yes
  22543. else
  22544. AST_PRI_CALL_HOLD_FOUND=no
  22545. fi
  22546. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22547. fi
  22548. # now check for the header.
  22549. if test "${AST_PRI_CALL_HOLD_FOUND}" = "yes"; then
  22550. PRI_CALL_HOLD_LIB="${pbxlibdir} -lpri "
  22551. # if --with-PRI_CALL_HOLD=DIR has been specified, use it.
  22552. if test "x${PRI_CALL_HOLD_DIR}" != "x"; then
  22553. PRI_CALL_HOLD_INCLUDE="-I${PRI_CALL_HOLD_DIR}/include"
  22554. fi
  22555. PRI_CALL_HOLD_INCLUDE="${PRI_CALL_HOLD_INCLUDE} "
  22556. if test "xlibpri.h" = "x" ; then # no header, assume found
  22557. PRI_CALL_HOLD_HEADER_FOUND="1"
  22558. else # check for the header
  22559. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22560. CPPFLAGS="${CPPFLAGS} ${PRI_CALL_HOLD_INCLUDE}"
  22561. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22562. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22563. PRI_CALL_HOLD_HEADER_FOUND=1
  22564. else
  22565. PRI_CALL_HOLD_HEADER_FOUND=0
  22566. fi
  22567. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22568. fi
  22569. if test "x${PRI_CALL_HOLD_HEADER_FOUND}" = "x0" ; then
  22570. PRI_CALL_HOLD_LIB=""
  22571. PRI_CALL_HOLD_INCLUDE=""
  22572. else
  22573. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22574. PRI_CALL_HOLD_LIB=""
  22575. fi
  22576. PBX_PRI_CALL_HOLD=1
  22577. cat >>confdefs.h <<_ACEOF
  22578. #define HAVE_PRI_CALL_HOLD 1
  22579. _ACEOF
  22580. fi
  22581. fi
  22582. fi
  22583. if test "x${PBX_PRI_CALL_REROUTING}" != "x1" -a "${USE_PRI_CALL_REROUTING}" != "no"; then
  22584. pbxlibdir=""
  22585. # if --with-PRI_CALL_REROUTING=DIR has been specified, use it.
  22586. if test "x${PRI_CALL_REROUTING_DIR}" != "x"; then
  22587. if test -d ${PRI_CALL_REROUTING_DIR}/lib; then
  22588. pbxlibdir="-L${PRI_CALL_REROUTING_DIR}/lib"
  22589. else
  22590. pbxlibdir="-L${PRI_CALL_REROUTING_DIR}"
  22591. fi
  22592. fi
  22593. pbxfuncname="pri_reroute_enable"
  22594. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22595. AST_PRI_CALL_REROUTING_FOUND=yes
  22596. else
  22597. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22598. CFLAGS="${CFLAGS} "
  22599. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22600. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22601. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22602. if eval \${$as_ac_Lib+:} false; then :
  22603. $as_echo_n "(cached) " >&6
  22604. else
  22605. ac_check_lib_save_LIBS=$LIBS
  22606. LIBS="-lpri ${pbxlibdir} $LIBS"
  22607. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22608. /* end confdefs.h. */
  22609. /* Override any GCC internal prototype to avoid an error.
  22610. Use char because int might match the return type of a GCC
  22611. builtin and then its argument prototype would still apply. */
  22612. #ifdef __cplusplus
  22613. extern "C"
  22614. #endif
  22615. char ${pbxfuncname} ();
  22616. int
  22617. main ()
  22618. {
  22619. return ${pbxfuncname} ();
  22620. ;
  22621. return 0;
  22622. }
  22623. _ACEOF
  22624. if ac_fn_c_try_link "$LINENO"; then :
  22625. eval "$as_ac_Lib=yes"
  22626. else
  22627. eval "$as_ac_Lib=no"
  22628. fi
  22629. rm -f core conftest.err conftest.$ac_objext \
  22630. conftest$ac_exeext conftest.$ac_ext
  22631. LIBS=$ac_check_lib_save_LIBS
  22632. fi
  22633. eval ac_res=\$$as_ac_Lib
  22634. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22635. $as_echo "$ac_res" >&6; }
  22636. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22637. AST_PRI_CALL_REROUTING_FOUND=yes
  22638. else
  22639. AST_PRI_CALL_REROUTING_FOUND=no
  22640. fi
  22641. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22642. fi
  22643. # now check for the header.
  22644. if test "${AST_PRI_CALL_REROUTING_FOUND}" = "yes"; then
  22645. PRI_CALL_REROUTING_LIB="${pbxlibdir} -lpri "
  22646. # if --with-PRI_CALL_REROUTING=DIR has been specified, use it.
  22647. if test "x${PRI_CALL_REROUTING_DIR}" != "x"; then
  22648. PRI_CALL_REROUTING_INCLUDE="-I${PRI_CALL_REROUTING_DIR}/include"
  22649. fi
  22650. PRI_CALL_REROUTING_INCLUDE="${PRI_CALL_REROUTING_INCLUDE} "
  22651. if test "xlibpri.h" = "x" ; then # no header, assume found
  22652. PRI_CALL_REROUTING_HEADER_FOUND="1"
  22653. else # check for the header
  22654. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22655. CPPFLAGS="${CPPFLAGS} ${PRI_CALL_REROUTING_INCLUDE}"
  22656. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22657. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22658. PRI_CALL_REROUTING_HEADER_FOUND=1
  22659. else
  22660. PRI_CALL_REROUTING_HEADER_FOUND=0
  22661. fi
  22662. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22663. fi
  22664. if test "x${PRI_CALL_REROUTING_HEADER_FOUND}" = "x0" ; then
  22665. PRI_CALL_REROUTING_LIB=""
  22666. PRI_CALL_REROUTING_INCLUDE=""
  22667. else
  22668. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22669. PRI_CALL_REROUTING_LIB=""
  22670. fi
  22671. PBX_PRI_CALL_REROUTING=1
  22672. cat >>confdefs.h <<_ACEOF
  22673. #define HAVE_PRI_CALL_REROUTING 1
  22674. _ACEOF
  22675. fi
  22676. fi
  22677. fi
  22678. if test "x${PBX_PRI_SETUP_KEYPAD}" != "x1" -a "${USE_PRI_SETUP_KEYPAD}" != "no"; then
  22679. pbxlibdir=""
  22680. # if --with-PRI_SETUP_KEYPAD=DIR has been specified, use it.
  22681. if test "x${PRI_SETUP_KEYPAD_DIR}" != "x"; then
  22682. if test -d ${PRI_SETUP_KEYPAD_DIR}/lib; then
  22683. pbxlibdir="-L${PRI_SETUP_KEYPAD_DIR}/lib"
  22684. else
  22685. pbxlibdir="-L${PRI_SETUP_KEYPAD_DIR}"
  22686. fi
  22687. fi
  22688. pbxfuncname="pri_sr_set_keypad_digits"
  22689. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22690. AST_PRI_SETUP_KEYPAD_FOUND=yes
  22691. else
  22692. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22693. CFLAGS="${CFLAGS} "
  22694. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22695. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22696. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22697. if eval \${$as_ac_Lib+:} false; then :
  22698. $as_echo_n "(cached) " >&6
  22699. else
  22700. ac_check_lib_save_LIBS=$LIBS
  22701. LIBS="-lpri ${pbxlibdir} $LIBS"
  22702. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22703. /* end confdefs.h. */
  22704. /* Override any GCC internal prototype to avoid an error.
  22705. Use char because int might match the return type of a GCC
  22706. builtin and then its argument prototype would still apply. */
  22707. #ifdef __cplusplus
  22708. extern "C"
  22709. #endif
  22710. char ${pbxfuncname} ();
  22711. int
  22712. main ()
  22713. {
  22714. return ${pbxfuncname} ();
  22715. ;
  22716. return 0;
  22717. }
  22718. _ACEOF
  22719. if ac_fn_c_try_link "$LINENO"; then :
  22720. eval "$as_ac_Lib=yes"
  22721. else
  22722. eval "$as_ac_Lib=no"
  22723. fi
  22724. rm -f core conftest.err conftest.$ac_objext \
  22725. conftest$ac_exeext conftest.$ac_ext
  22726. LIBS=$ac_check_lib_save_LIBS
  22727. fi
  22728. eval ac_res=\$$as_ac_Lib
  22729. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22730. $as_echo "$ac_res" >&6; }
  22731. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22732. AST_PRI_SETUP_KEYPAD_FOUND=yes
  22733. else
  22734. AST_PRI_SETUP_KEYPAD_FOUND=no
  22735. fi
  22736. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22737. fi
  22738. # now check for the header.
  22739. if test "${AST_PRI_SETUP_KEYPAD_FOUND}" = "yes"; then
  22740. PRI_SETUP_KEYPAD_LIB="${pbxlibdir} -lpri "
  22741. # if --with-PRI_SETUP_KEYPAD=DIR has been specified, use it.
  22742. if test "x${PRI_SETUP_KEYPAD_DIR}" != "x"; then
  22743. PRI_SETUP_KEYPAD_INCLUDE="-I${PRI_SETUP_KEYPAD_DIR}/include"
  22744. fi
  22745. PRI_SETUP_KEYPAD_INCLUDE="${PRI_SETUP_KEYPAD_INCLUDE} "
  22746. if test "xlibpri.h" = "x" ; then # no header, assume found
  22747. PRI_SETUP_KEYPAD_HEADER_FOUND="1"
  22748. else # check for the header
  22749. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22750. CPPFLAGS="${CPPFLAGS} ${PRI_SETUP_KEYPAD_INCLUDE}"
  22751. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22752. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22753. PRI_SETUP_KEYPAD_HEADER_FOUND=1
  22754. else
  22755. PRI_SETUP_KEYPAD_HEADER_FOUND=0
  22756. fi
  22757. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22758. fi
  22759. if test "x${PRI_SETUP_KEYPAD_HEADER_FOUND}" = "x0" ; then
  22760. PRI_SETUP_KEYPAD_LIB=""
  22761. PRI_SETUP_KEYPAD_INCLUDE=""
  22762. else
  22763. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22764. PRI_SETUP_KEYPAD_LIB=""
  22765. fi
  22766. PBX_PRI_SETUP_KEYPAD=1
  22767. cat >>confdefs.h <<_ACEOF
  22768. #define HAVE_PRI_SETUP_KEYPAD 1
  22769. _ACEOF
  22770. fi
  22771. fi
  22772. fi
  22773. # ------------------------------------v
  22774. # TODO: The code can be changed to always include these features now.
  22775. # These features will always be present if pri_connected_line_update is available.
  22776. if test "x${PBX_PRI_PROG_W_CAUSE}" != "x1" -a "${USE_PRI_PROG_W_CAUSE}" != "no"; then
  22777. pbxlibdir=""
  22778. # if --with-PRI_PROG_W_CAUSE=DIR has been specified, use it.
  22779. if test "x${PRI_PROG_W_CAUSE_DIR}" != "x"; then
  22780. if test -d ${PRI_PROG_W_CAUSE_DIR}/lib; then
  22781. pbxlibdir="-L${PRI_PROG_W_CAUSE_DIR}/lib"
  22782. else
  22783. pbxlibdir="-L${PRI_PROG_W_CAUSE_DIR}"
  22784. fi
  22785. fi
  22786. pbxfuncname="pri_progress_with_cause"
  22787. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22788. AST_PRI_PROG_W_CAUSE_FOUND=yes
  22789. else
  22790. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22791. CFLAGS="${CFLAGS} "
  22792. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22793. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22794. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22795. if eval \${$as_ac_Lib+:} false; then :
  22796. $as_echo_n "(cached) " >&6
  22797. else
  22798. ac_check_lib_save_LIBS=$LIBS
  22799. LIBS="-lpri ${pbxlibdir} $LIBS"
  22800. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22801. /* end confdefs.h. */
  22802. /* Override any GCC internal prototype to avoid an error.
  22803. Use char because int might match the return type of a GCC
  22804. builtin and then its argument prototype would still apply. */
  22805. #ifdef __cplusplus
  22806. extern "C"
  22807. #endif
  22808. char ${pbxfuncname} ();
  22809. int
  22810. main ()
  22811. {
  22812. return ${pbxfuncname} ();
  22813. ;
  22814. return 0;
  22815. }
  22816. _ACEOF
  22817. if ac_fn_c_try_link "$LINENO"; then :
  22818. eval "$as_ac_Lib=yes"
  22819. else
  22820. eval "$as_ac_Lib=no"
  22821. fi
  22822. rm -f core conftest.err conftest.$ac_objext \
  22823. conftest$ac_exeext conftest.$ac_ext
  22824. LIBS=$ac_check_lib_save_LIBS
  22825. fi
  22826. eval ac_res=\$$as_ac_Lib
  22827. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22828. $as_echo "$ac_res" >&6; }
  22829. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22830. AST_PRI_PROG_W_CAUSE_FOUND=yes
  22831. else
  22832. AST_PRI_PROG_W_CAUSE_FOUND=no
  22833. fi
  22834. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22835. fi
  22836. # now check for the header.
  22837. if test "${AST_PRI_PROG_W_CAUSE_FOUND}" = "yes"; then
  22838. PRI_PROG_W_CAUSE_LIB="${pbxlibdir} -lpri "
  22839. # if --with-PRI_PROG_W_CAUSE=DIR has been specified, use it.
  22840. if test "x${PRI_PROG_W_CAUSE_DIR}" != "x"; then
  22841. PRI_PROG_W_CAUSE_INCLUDE="-I${PRI_PROG_W_CAUSE_DIR}/include"
  22842. fi
  22843. PRI_PROG_W_CAUSE_INCLUDE="${PRI_PROG_W_CAUSE_INCLUDE} "
  22844. if test "xlibpri.h" = "x" ; then # no header, assume found
  22845. PRI_PROG_W_CAUSE_HEADER_FOUND="1"
  22846. else # check for the header
  22847. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22848. CPPFLAGS="${CPPFLAGS} ${PRI_PROG_W_CAUSE_INCLUDE}"
  22849. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22850. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22851. PRI_PROG_W_CAUSE_HEADER_FOUND=1
  22852. else
  22853. PRI_PROG_W_CAUSE_HEADER_FOUND=0
  22854. fi
  22855. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22856. fi
  22857. if test "x${PRI_PROG_W_CAUSE_HEADER_FOUND}" = "x0" ; then
  22858. PRI_PROG_W_CAUSE_LIB=""
  22859. PRI_PROG_W_CAUSE_INCLUDE=""
  22860. else
  22861. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22862. PRI_PROG_W_CAUSE_LIB=""
  22863. fi
  22864. PBX_PRI_PROG_W_CAUSE=1
  22865. cat >>confdefs.h <<_ACEOF
  22866. #define HAVE_PRI_PROG_W_CAUSE 1
  22867. _ACEOF
  22868. fi
  22869. fi
  22870. fi
  22871. if test "x${PBX_PRI_INBANDDISCONNECT}" != "x1" -a "${USE_PRI_INBANDDISCONNECT}" != "no"; then
  22872. pbxlibdir=""
  22873. # if --with-PRI_INBANDDISCONNECT=DIR has been specified, use it.
  22874. if test "x${PRI_INBANDDISCONNECT_DIR}" != "x"; then
  22875. if test -d ${PRI_INBANDDISCONNECT_DIR}/lib; then
  22876. pbxlibdir="-L${PRI_INBANDDISCONNECT_DIR}/lib"
  22877. else
  22878. pbxlibdir="-L${PRI_INBANDDISCONNECT_DIR}"
  22879. fi
  22880. fi
  22881. pbxfuncname="pri_set_inbanddisconnect"
  22882. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22883. AST_PRI_INBANDDISCONNECT_FOUND=yes
  22884. else
  22885. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22886. CFLAGS="${CFLAGS} "
  22887. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22888. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22889. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22890. if eval \${$as_ac_Lib+:} false; then :
  22891. $as_echo_n "(cached) " >&6
  22892. else
  22893. ac_check_lib_save_LIBS=$LIBS
  22894. LIBS="-lpri ${pbxlibdir} $LIBS"
  22895. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22896. /* end confdefs.h. */
  22897. /* Override any GCC internal prototype to avoid an error.
  22898. Use char because int might match the return type of a GCC
  22899. builtin and then its argument prototype would still apply. */
  22900. #ifdef __cplusplus
  22901. extern "C"
  22902. #endif
  22903. char ${pbxfuncname} ();
  22904. int
  22905. main ()
  22906. {
  22907. return ${pbxfuncname} ();
  22908. ;
  22909. return 0;
  22910. }
  22911. _ACEOF
  22912. if ac_fn_c_try_link "$LINENO"; then :
  22913. eval "$as_ac_Lib=yes"
  22914. else
  22915. eval "$as_ac_Lib=no"
  22916. fi
  22917. rm -f core conftest.err conftest.$ac_objext \
  22918. conftest$ac_exeext conftest.$ac_ext
  22919. LIBS=$ac_check_lib_save_LIBS
  22920. fi
  22921. eval ac_res=\$$as_ac_Lib
  22922. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  22923. $as_echo "$ac_res" >&6; }
  22924. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  22925. AST_PRI_INBANDDISCONNECT_FOUND=yes
  22926. else
  22927. AST_PRI_INBANDDISCONNECT_FOUND=no
  22928. fi
  22929. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  22930. fi
  22931. # now check for the header.
  22932. if test "${AST_PRI_INBANDDISCONNECT_FOUND}" = "yes"; then
  22933. PRI_INBANDDISCONNECT_LIB="${pbxlibdir} -lpri "
  22934. # if --with-PRI_INBANDDISCONNECT=DIR has been specified, use it.
  22935. if test "x${PRI_INBANDDISCONNECT_DIR}" != "x"; then
  22936. PRI_INBANDDISCONNECT_INCLUDE="-I${PRI_INBANDDISCONNECT_DIR}/include"
  22937. fi
  22938. PRI_INBANDDISCONNECT_INCLUDE="${PRI_INBANDDISCONNECT_INCLUDE} "
  22939. if test "xlibpri.h" = "x" ; then # no header, assume found
  22940. PRI_INBANDDISCONNECT_HEADER_FOUND="1"
  22941. else # check for the header
  22942. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  22943. CPPFLAGS="${CPPFLAGS} ${PRI_INBANDDISCONNECT_INCLUDE}"
  22944. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  22945. if test "x$ac_cv_header_libpri_h" = xyes; then :
  22946. PRI_INBANDDISCONNECT_HEADER_FOUND=1
  22947. else
  22948. PRI_INBANDDISCONNECT_HEADER_FOUND=0
  22949. fi
  22950. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  22951. fi
  22952. if test "x${PRI_INBANDDISCONNECT_HEADER_FOUND}" = "x0" ; then
  22953. PRI_INBANDDISCONNECT_LIB=""
  22954. PRI_INBANDDISCONNECT_INCLUDE=""
  22955. else
  22956. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  22957. PRI_INBANDDISCONNECT_LIB=""
  22958. fi
  22959. PBX_PRI_INBANDDISCONNECT=1
  22960. cat >>confdefs.h <<_ACEOF
  22961. #define HAVE_PRI_INBANDDISCONNECT 1
  22962. _ACEOF
  22963. fi
  22964. fi
  22965. fi
  22966. if test "x${PBX_PRI_SERVICE_MESSAGES}" != "x1" -a "${USE_PRI_SERVICE_MESSAGES}" != "no"; then
  22967. pbxlibdir=""
  22968. # if --with-PRI_SERVICE_MESSAGES=DIR has been specified, use it.
  22969. if test "x${PRI_SERVICE_MESSAGES_DIR}" != "x"; then
  22970. if test -d ${PRI_SERVICE_MESSAGES_DIR}/lib; then
  22971. pbxlibdir="-L${PRI_SERVICE_MESSAGES_DIR}/lib"
  22972. else
  22973. pbxlibdir="-L${PRI_SERVICE_MESSAGES_DIR}"
  22974. fi
  22975. fi
  22976. pbxfuncname="pri_maintenance_service"
  22977. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  22978. AST_PRI_SERVICE_MESSAGES_FOUND=yes
  22979. else
  22980. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  22981. CFLAGS="${CFLAGS} "
  22982. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  22983. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  22984. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  22985. if eval \${$as_ac_Lib+:} false; then :
  22986. $as_echo_n "(cached) " >&6
  22987. else
  22988. ac_check_lib_save_LIBS=$LIBS
  22989. LIBS="-lpri ${pbxlibdir} $LIBS"
  22990. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  22991. /* end confdefs.h. */
  22992. /* Override any GCC internal prototype to avoid an error.
  22993. Use char because int might match the return type of a GCC
  22994. builtin and then its argument prototype would still apply. */
  22995. #ifdef __cplusplus
  22996. extern "C"
  22997. #endif
  22998. char ${pbxfuncname} ();
  22999. int
  23000. main ()
  23001. {
  23002. return ${pbxfuncname} ();
  23003. ;
  23004. return 0;
  23005. }
  23006. _ACEOF
  23007. if ac_fn_c_try_link "$LINENO"; then :
  23008. eval "$as_ac_Lib=yes"
  23009. else
  23010. eval "$as_ac_Lib=no"
  23011. fi
  23012. rm -f core conftest.err conftest.$ac_objext \
  23013. conftest$ac_exeext conftest.$ac_ext
  23014. LIBS=$ac_check_lib_save_LIBS
  23015. fi
  23016. eval ac_res=\$$as_ac_Lib
  23017. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23018. $as_echo "$ac_res" >&6; }
  23019. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23020. AST_PRI_SERVICE_MESSAGES_FOUND=yes
  23021. else
  23022. AST_PRI_SERVICE_MESSAGES_FOUND=no
  23023. fi
  23024. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23025. fi
  23026. # now check for the header.
  23027. if test "${AST_PRI_SERVICE_MESSAGES_FOUND}" = "yes"; then
  23028. PRI_SERVICE_MESSAGES_LIB="${pbxlibdir} -lpri "
  23029. # if --with-PRI_SERVICE_MESSAGES=DIR has been specified, use it.
  23030. if test "x${PRI_SERVICE_MESSAGES_DIR}" != "x"; then
  23031. PRI_SERVICE_MESSAGES_INCLUDE="-I${PRI_SERVICE_MESSAGES_DIR}/include"
  23032. fi
  23033. PRI_SERVICE_MESSAGES_INCLUDE="${PRI_SERVICE_MESSAGES_INCLUDE} "
  23034. if test "xlibpri.h" = "x" ; then # no header, assume found
  23035. PRI_SERVICE_MESSAGES_HEADER_FOUND="1"
  23036. else # check for the header
  23037. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23038. CPPFLAGS="${CPPFLAGS} ${PRI_SERVICE_MESSAGES_INCLUDE}"
  23039. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  23040. if test "x$ac_cv_header_libpri_h" = xyes; then :
  23041. PRI_SERVICE_MESSAGES_HEADER_FOUND=1
  23042. else
  23043. PRI_SERVICE_MESSAGES_HEADER_FOUND=0
  23044. fi
  23045. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23046. fi
  23047. if test "x${PRI_SERVICE_MESSAGES_HEADER_FOUND}" = "x0" ; then
  23048. PRI_SERVICE_MESSAGES_LIB=""
  23049. PRI_SERVICE_MESSAGES_INCLUDE=""
  23050. else
  23051. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23052. PRI_SERVICE_MESSAGES_LIB=""
  23053. fi
  23054. PBX_PRI_SERVICE_MESSAGES=1
  23055. cat >>confdefs.h <<_ACEOF
  23056. #define HAVE_PRI_SERVICE_MESSAGES 1
  23057. _ACEOF
  23058. fi
  23059. fi
  23060. fi
  23061. if test "x${PBX_PRI_REVERSE_CHARGE}" != "x1" -a "${USE_PRI_REVERSE_CHARGE}" != "no"; then
  23062. pbxlibdir=""
  23063. # if --with-PRI_REVERSE_CHARGE=DIR has been specified, use it.
  23064. if test "x${PRI_REVERSE_CHARGE_DIR}" != "x"; then
  23065. if test -d ${PRI_REVERSE_CHARGE_DIR}/lib; then
  23066. pbxlibdir="-L${PRI_REVERSE_CHARGE_DIR}/lib"
  23067. else
  23068. pbxlibdir="-L${PRI_REVERSE_CHARGE_DIR}"
  23069. fi
  23070. fi
  23071. pbxfuncname="pri_sr_set_reversecharge"
  23072. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23073. AST_PRI_REVERSE_CHARGE_FOUND=yes
  23074. else
  23075. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23076. CFLAGS="${CFLAGS} "
  23077. as_ac_Lib=`$as_echo "ac_cv_lib_pri_${pbxfuncname}" | $as_tr_sh`
  23078. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lpri" >&5
  23079. $as_echo_n "checking for ${pbxfuncname} in -lpri... " >&6; }
  23080. if eval \${$as_ac_Lib+:} false; then :
  23081. $as_echo_n "(cached) " >&6
  23082. else
  23083. ac_check_lib_save_LIBS=$LIBS
  23084. LIBS="-lpri ${pbxlibdir} $LIBS"
  23085. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23086. /* end confdefs.h. */
  23087. /* Override any GCC internal prototype to avoid an error.
  23088. Use char because int might match the return type of a GCC
  23089. builtin and then its argument prototype would still apply. */
  23090. #ifdef __cplusplus
  23091. extern "C"
  23092. #endif
  23093. char ${pbxfuncname} ();
  23094. int
  23095. main ()
  23096. {
  23097. return ${pbxfuncname} ();
  23098. ;
  23099. return 0;
  23100. }
  23101. _ACEOF
  23102. if ac_fn_c_try_link "$LINENO"; then :
  23103. eval "$as_ac_Lib=yes"
  23104. else
  23105. eval "$as_ac_Lib=no"
  23106. fi
  23107. rm -f core conftest.err conftest.$ac_objext \
  23108. conftest$ac_exeext conftest.$ac_ext
  23109. LIBS=$ac_check_lib_save_LIBS
  23110. fi
  23111. eval ac_res=\$$as_ac_Lib
  23112. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23113. $as_echo "$ac_res" >&6; }
  23114. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23115. AST_PRI_REVERSE_CHARGE_FOUND=yes
  23116. else
  23117. AST_PRI_REVERSE_CHARGE_FOUND=no
  23118. fi
  23119. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23120. fi
  23121. # now check for the header.
  23122. if test "${AST_PRI_REVERSE_CHARGE_FOUND}" = "yes"; then
  23123. PRI_REVERSE_CHARGE_LIB="${pbxlibdir} -lpri "
  23124. # if --with-PRI_REVERSE_CHARGE=DIR has been specified, use it.
  23125. if test "x${PRI_REVERSE_CHARGE_DIR}" != "x"; then
  23126. PRI_REVERSE_CHARGE_INCLUDE="-I${PRI_REVERSE_CHARGE_DIR}/include"
  23127. fi
  23128. PRI_REVERSE_CHARGE_INCLUDE="${PRI_REVERSE_CHARGE_INCLUDE} "
  23129. if test "xlibpri.h" = "x" ; then # no header, assume found
  23130. PRI_REVERSE_CHARGE_HEADER_FOUND="1"
  23131. else # check for the header
  23132. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23133. CPPFLAGS="${CPPFLAGS} ${PRI_REVERSE_CHARGE_INCLUDE}"
  23134. ac_fn_c_check_header_mongrel "$LINENO" "libpri.h" "ac_cv_header_libpri_h" "$ac_includes_default"
  23135. if test "x$ac_cv_header_libpri_h" = xyes; then :
  23136. PRI_REVERSE_CHARGE_HEADER_FOUND=1
  23137. else
  23138. PRI_REVERSE_CHARGE_HEADER_FOUND=0
  23139. fi
  23140. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23141. fi
  23142. if test "x${PRI_REVERSE_CHARGE_HEADER_FOUND}" = "x0" ; then
  23143. PRI_REVERSE_CHARGE_LIB=""
  23144. PRI_REVERSE_CHARGE_INCLUDE=""
  23145. else
  23146. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23147. PRI_REVERSE_CHARGE_LIB=""
  23148. fi
  23149. PBX_PRI_REVERSE_CHARGE=1
  23150. cat >>confdefs.h <<_ACEOF
  23151. #define HAVE_PRI_REVERSE_CHARGE 1
  23152. _ACEOF
  23153. fi
  23154. fi
  23155. fi
  23156. # ------------------------------------^
  23157. if test "x${PBX_RESAMPLE}" != "x1" -a "${USE_RESAMPLE}" != "no"; then
  23158. pbxlibdir=""
  23159. # if --with-RESAMPLE=DIR has been specified, use it.
  23160. if test "x${RESAMPLE_DIR}" != "x"; then
  23161. if test -d ${RESAMPLE_DIR}/lib; then
  23162. pbxlibdir="-L${RESAMPLE_DIR}/lib"
  23163. else
  23164. pbxlibdir="-L${RESAMPLE_DIR}"
  23165. fi
  23166. fi
  23167. pbxfuncname="resample_open"
  23168. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23169. AST_RESAMPLE_FOUND=yes
  23170. else
  23171. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23172. CFLAGS="${CFLAGS} "
  23173. as_ac_Lib=`$as_echo "ac_cv_lib_resample_${pbxfuncname}" | $as_tr_sh`
  23174. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lresample" >&5
  23175. $as_echo_n "checking for ${pbxfuncname} in -lresample... " >&6; }
  23176. if eval \${$as_ac_Lib+:} false; then :
  23177. $as_echo_n "(cached) " >&6
  23178. else
  23179. ac_check_lib_save_LIBS=$LIBS
  23180. LIBS="-lresample ${pbxlibdir} -lm $LIBS"
  23181. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23182. /* end confdefs.h. */
  23183. /* Override any GCC internal prototype to avoid an error.
  23184. Use char because int might match the return type of a GCC
  23185. builtin and then its argument prototype would still apply. */
  23186. #ifdef __cplusplus
  23187. extern "C"
  23188. #endif
  23189. char ${pbxfuncname} ();
  23190. int
  23191. main ()
  23192. {
  23193. return ${pbxfuncname} ();
  23194. ;
  23195. return 0;
  23196. }
  23197. _ACEOF
  23198. if ac_fn_c_try_link "$LINENO"; then :
  23199. eval "$as_ac_Lib=yes"
  23200. else
  23201. eval "$as_ac_Lib=no"
  23202. fi
  23203. rm -f core conftest.err conftest.$ac_objext \
  23204. conftest$ac_exeext conftest.$ac_ext
  23205. LIBS=$ac_check_lib_save_LIBS
  23206. fi
  23207. eval ac_res=\$$as_ac_Lib
  23208. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23209. $as_echo "$ac_res" >&6; }
  23210. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23211. AST_RESAMPLE_FOUND=yes
  23212. else
  23213. AST_RESAMPLE_FOUND=no
  23214. fi
  23215. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23216. fi
  23217. # now check for the header.
  23218. if test "${AST_RESAMPLE_FOUND}" = "yes"; then
  23219. RESAMPLE_LIB="${pbxlibdir} -lresample -lm"
  23220. # if --with-RESAMPLE=DIR has been specified, use it.
  23221. if test "x${RESAMPLE_DIR}" != "x"; then
  23222. RESAMPLE_INCLUDE="-I${RESAMPLE_DIR}/include"
  23223. fi
  23224. RESAMPLE_INCLUDE="${RESAMPLE_INCLUDE} "
  23225. if test "xlibresample.h" = "x" ; then # no header, assume found
  23226. RESAMPLE_HEADER_FOUND="1"
  23227. else # check for the header
  23228. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23229. CPPFLAGS="${CPPFLAGS} ${RESAMPLE_INCLUDE}"
  23230. ac_fn_c_check_header_mongrel "$LINENO" "libresample.h" "ac_cv_header_libresample_h" "$ac_includes_default"
  23231. if test "x$ac_cv_header_libresample_h" = xyes; then :
  23232. RESAMPLE_HEADER_FOUND=1
  23233. else
  23234. RESAMPLE_HEADER_FOUND=0
  23235. fi
  23236. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23237. fi
  23238. if test "x${RESAMPLE_HEADER_FOUND}" = "x0" ; then
  23239. RESAMPLE_LIB=""
  23240. RESAMPLE_INCLUDE=""
  23241. else
  23242. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23243. RESAMPLE_LIB=""
  23244. fi
  23245. PBX_RESAMPLE=1
  23246. cat >>confdefs.h <<_ACEOF
  23247. #define HAVE_RESAMPLE 1
  23248. _ACEOF
  23249. fi
  23250. fi
  23251. fi
  23252. if test "x${PBX_SPANDSP}" != "x1" -a "${USE_SPANDSP}" != "no"; then
  23253. if test "xminimum version of SpanDSP" != "x"; then
  23254. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for minimum version of SpanDSP" >&5
  23255. $as_echo_n "checking for minimum version of SpanDSP... " >&6; }
  23256. else
  23257. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if \"
  23258. #if SPANDSP_RELEASE_DATE < 20080516
  23259. #error \"spandsp 0.0.5 or greater is required\"
  23260. #endif
  23261. \" compiles using spandsp/version.h" >&5
  23262. $as_echo_n "checking if \"
  23263. #if SPANDSP_RELEASE_DATE < 20080516
  23264. #error \"spandsp 0.0.5 or greater is required\"
  23265. #endif
  23266. \" compiles using spandsp/version.h... " >&6; }
  23267. fi
  23268. saved_cppflags="${CPPFLAGS}"
  23269. if test "x${SPANDSP_DIR}" != "x"; then
  23270. SPANDSP_INCLUDE="-I${SPANDSP_DIR}/include"
  23271. fi
  23272. CPPFLAGS="${CPPFLAGS} ${SPANDSP_INCLUDE}"
  23273. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23274. /* end confdefs.h. */
  23275. #include <spandsp/version.h>
  23276. int
  23277. main ()
  23278. {
  23279. #if SPANDSP_RELEASE_DATE < 20080516
  23280. #error "spandsp 0.0.5 or greater is required"
  23281. #endif
  23282. ;
  23283. ;
  23284. return 0;
  23285. }
  23286. _ACEOF
  23287. if ac_fn_c_try_compile "$LINENO"; then :
  23288. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  23289. $as_echo "yes" >&6; }
  23290. PBX_SPANDSP=1
  23291. $as_echo "#define HAVE_SPANDSP 1" >>confdefs.h
  23292. else
  23293. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23294. $as_echo "no" >&6; }
  23295. fi
  23296. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  23297. CPPFLAGS="${saved_cppflags}"
  23298. fi
  23299. if test "x${PBX_SPANDSP}" = "x1" ; then
  23300. # We found the correct version in the header, now let's make sure it links
  23301. # properly, and that libtiff is available
  23302. PBX_SPANDSP=0
  23303. if test "x${PBX_SPANDSP}" != "x1" -a "${USE_SPANDSP}" != "no"; then
  23304. pbxlibdir=""
  23305. # if --with-SPANDSP=DIR has been specified, use it.
  23306. if test "x${SPANDSP_DIR}" != "x"; then
  23307. if test -d ${SPANDSP_DIR}/lib; then
  23308. pbxlibdir="-L${SPANDSP_DIR}/lib"
  23309. else
  23310. pbxlibdir="-L${SPANDSP_DIR}"
  23311. fi
  23312. fi
  23313. pbxfuncname="span_set_message_handler"
  23314. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23315. AST_SPANDSP_FOUND=yes
  23316. else
  23317. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23318. CFLAGS="${CFLAGS} "
  23319. as_ac_Lib=`$as_echo "ac_cv_lib_spandsp_${pbxfuncname}" | $as_tr_sh`
  23320. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspandsp" >&5
  23321. $as_echo_n "checking for ${pbxfuncname} in -lspandsp... " >&6; }
  23322. if eval \${$as_ac_Lib+:} false; then :
  23323. $as_echo_n "(cached) " >&6
  23324. else
  23325. ac_check_lib_save_LIBS=$LIBS
  23326. LIBS="-lspandsp ${pbxlibdir} -ltiff $LIBS"
  23327. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23328. /* end confdefs.h. */
  23329. /* Override any GCC internal prototype to avoid an error.
  23330. Use char because int might match the return type of a GCC
  23331. builtin and then its argument prototype would still apply. */
  23332. #ifdef __cplusplus
  23333. extern "C"
  23334. #endif
  23335. char ${pbxfuncname} ();
  23336. int
  23337. main ()
  23338. {
  23339. return ${pbxfuncname} ();
  23340. ;
  23341. return 0;
  23342. }
  23343. _ACEOF
  23344. if ac_fn_c_try_link "$LINENO"; then :
  23345. eval "$as_ac_Lib=yes"
  23346. else
  23347. eval "$as_ac_Lib=no"
  23348. fi
  23349. rm -f core conftest.err conftest.$ac_objext \
  23350. conftest$ac_exeext conftest.$ac_ext
  23351. LIBS=$ac_check_lib_save_LIBS
  23352. fi
  23353. eval ac_res=\$$as_ac_Lib
  23354. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23355. $as_echo "$ac_res" >&6; }
  23356. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23357. AST_SPANDSP_FOUND=yes
  23358. else
  23359. AST_SPANDSP_FOUND=no
  23360. fi
  23361. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23362. fi
  23363. # now check for the header.
  23364. if test "${AST_SPANDSP_FOUND}" = "yes"; then
  23365. SPANDSP_LIB="${pbxlibdir} -lspandsp -ltiff"
  23366. # if --with-SPANDSP=DIR has been specified, use it.
  23367. if test "x${SPANDSP_DIR}" != "x"; then
  23368. SPANDSP_INCLUDE="-I${SPANDSP_DIR}/include"
  23369. fi
  23370. SPANDSP_INCLUDE="${SPANDSP_INCLUDE} "
  23371. if test "xspandsp.h" = "x" ; then # no header, assume found
  23372. SPANDSP_HEADER_FOUND="1"
  23373. else # check for the header
  23374. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23375. CPPFLAGS="${CPPFLAGS} ${SPANDSP_INCLUDE}"
  23376. ac_fn_c_check_header_mongrel "$LINENO" "spandsp.h" "ac_cv_header_spandsp_h" "$ac_includes_default"
  23377. if test "x$ac_cv_header_spandsp_h" = xyes; then :
  23378. SPANDSP_HEADER_FOUND=1
  23379. else
  23380. SPANDSP_HEADER_FOUND=0
  23381. fi
  23382. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23383. fi
  23384. if test "x${SPANDSP_HEADER_FOUND}" = "x0" ; then
  23385. SPANDSP_LIB=""
  23386. SPANDSP_INCLUDE=""
  23387. else
  23388. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23389. SPANDSP_LIB=""
  23390. fi
  23391. PBX_SPANDSP=1
  23392. cat >>confdefs.h <<_ACEOF
  23393. #define HAVE_SPANDSP 1
  23394. _ACEOF
  23395. fi
  23396. fi
  23397. fi
  23398. fi
  23399. if test "x${PBX_SPANDSP}" = "x1" ; then
  23400. # We also need t38_terminal_init()
  23401. PBX_SPANDSP=0
  23402. if test "x${PBX_SPANDSP}" != "x1" -a "${USE_SPANDSP}" != "no"; then
  23403. pbxlibdir=""
  23404. # if --with-SPANDSP=DIR has been specified, use it.
  23405. if test "x${SPANDSP_DIR}" != "x"; then
  23406. if test -d ${SPANDSP_DIR}/lib; then
  23407. pbxlibdir="-L${SPANDSP_DIR}/lib"
  23408. else
  23409. pbxlibdir="-L${SPANDSP_DIR}"
  23410. fi
  23411. fi
  23412. pbxfuncname="t38_terminal_init"
  23413. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23414. AST_SPANDSP_FOUND=yes
  23415. else
  23416. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23417. CFLAGS="${CFLAGS} "
  23418. as_ac_Lib=`$as_echo "ac_cv_lib_spandsp_${pbxfuncname}" | $as_tr_sh`
  23419. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspandsp" >&5
  23420. $as_echo_n "checking for ${pbxfuncname} in -lspandsp... " >&6; }
  23421. if eval \${$as_ac_Lib+:} false; then :
  23422. $as_echo_n "(cached) " >&6
  23423. else
  23424. ac_check_lib_save_LIBS=$LIBS
  23425. LIBS="-lspandsp ${pbxlibdir} -ltiff $LIBS"
  23426. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23427. /* end confdefs.h. */
  23428. /* Override any GCC internal prototype to avoid an error.
  23429. Use char because int might match the return type of a GCC
  23430. builtin and then its argument prototype would still apply. */
  23431. #ifdef __cplusplus
  23432. extern "C"
  23433. #endif
  23434. char ${pbxfuncname} ();
  23435. int
  23436. main ()
  23437. {
  23438. return ${pbxfuncname} ();
  23439. ;
  23440. return 0;
  23441. }
  23442. _ACEOF
  23443. if ac_fn_c_try_link "$LINENO"; then :
  23444. eval "$as_ac_Lib=yes"
  23445. else
  23446. eval "$as_ac_Lib=no"
  23447. fi
  23448. rm -f core conftest.err conftest.$ac_objext \
  23449. conftest$ac_exeext conftest.$ac_ext
  23450. LIBS=$ac_check_lib_save_LIBS
  23451. fi
  23452. eval ac_res=\$$as_ac_Lib
  23453. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23454. $as_echo "$ac_res" >&6; }
  23455. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23456. AST_SPANDSP_FOUND=yes
  23457. else
  23458. AST_SPANDSP_FOUND=no
  23459. fi
  23460. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23461. fi
  23462. # now check for the header.
  23463. if test "${AST_SPANDSP_FOUND}" = "yes"; then
  23464. SPANDSP_LIB="${pbxlibdir} -lspandsp -ltiff"
  23465. # if --with-SPANDSP=DIR has been specified, use it.
  23466. if test "x${SPANDSP_DIR}" != "x"; then
  23467. SPANDSP_INCLUDE="-I${SPANDSP_DIR}/include"
  23468. fi
  23469. SPANDSP_INCLUDE="${SPANDSP_INCLUDE} "
  23470. if test "xspandsp.h" = "x" ; then # no header, assume found
  23471. SPANDSP_HEADER_FOUND="1"
  23472. else # check for the header
  23473. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23474. CPPFLAGS="${CPPFLAGS} ${SPANDSP_INCLUDE}"
  23475. ac_fn_c_check_header_mongrel "$LINENO" "spandsp.h" "ac_cv_header_spandsp_h" "$ac_includes_default"
  23476. if test "x$ac_cv_header_spandsp_h" = xyes; then :
  23477. SPANDSP_HEADER_FOUND=1
  23478. else
  23479. SPANDSP_HEADER_FOUND=0
  23480. fi
  23481. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23482. fi
  23483. if test "x${SPANDSP_HEADER_FOUND}" = "x0" ; then
  23484. SPANDSP_LIB=""
  23485. SPANDSP_INCLUDE=""
  23486. else
  23487. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23488. SPANDSP_LIB=""
  23489. fi
  23490. PBX_SPANDSP=1
  23491. cat >>confdefs.h <<_ACEOF
  23492. #define HAVE_SPANDSP 1
  23493. _ACEOF
  23494. fi
  23495. fi
  23496. fi
  23497. fi
  23498. # Check for libss7 v2.0 branch compatible version.
  23499. if test "x${PBX_SS7}" != "x1" -a "${USE_SS7}" != "no"; then
  23500. pbxlibdir=""
  23501. # if --with-SS7=DIR has been specified, use it.
  23502. if test "x${SS7_DIR}" != "x"; then
  23503. if test -d ${SS7_DIR}/lib; then
  23504. pbxlibdir="-L${SS7_DIR}/lib"
  23505. else
  23506. pbxlibdir="-L${SS7_DIR}"
  23507. fi
  23508. fi
  23509. pbxfuncname="ss7_set_isup_timer"
  23510. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23511. AST_SS7_FOUND=yes
  23512. else
  23513. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23514. CFLAGS="${CFLAGS} "
  23515. as_ac_Lib=`$as_echo "ac_cv_lib_ss7_${pbxfuncname}" | $as_tr_sh`
  23516. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lss7" >&5
  23517. $as_echo_n "checking for ${pbxfuncname} in -lss7... " >&6; }
  23518. if eval \${$as_ac_Lib+:} false; then :
  23519. $as_echo_n "(cached) " >&6
  23520. else
  23521. ac_check_lib_save_LIBS=$LIBS
  23522. LIBS="-lss7 ${pbxlibdir} $LIBS"
  23523. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23524. /* end confdefs.h. */
  23525. /* Override any GCC internal prototype to avoid an error.
  23526. Use char because int might match the return type of a GCC
  23527. builtin and then its argument prototype would still apply. */
  23528. #ifdef __cplusplus
  23529. extern "C"
  23530. #endif
  23531. char ${pbxfuncname} ();
  23532. int
  23533. main ()
  23534. {
  23535. return ${pbxfuncname} ();
  23536. ;
  23537. return 0;
  23538. }
  23539. _ACEOF
  23540. if ac_fn_c_try_link "$LINENO"; then :
  23541. eval "$as_ac_Lib=yes"
  23542. else
  23543. eval "$as_ac_Lib=no"
  23544. fi
  23545. rm -f core conftest.err conftest.$ac_objext \
  23546. conftest$ac_exeext conftest.$ac_ext
  23547. LIBS=$ac_check_lib_save_LIBS
  23548. fi
  23549. eval ac_res=\$$as_ac_Lib
  23550. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23551. $as_echo "$ac_res" >&6; }
  23552. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23553. AST_SS7_FOUND=yes
  23554. else
  23555. AST_SS7_FOUND=no
  23556. fi
  23557. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23558. fi
  23559. # now check for the header.
  23560. if test "${AST_SS7_FOUND}" = "yes"; then
  23561. SS7_LIB="${pbxlibdir} -lss7 "
  23562. # if --with-SS7=DIR has been specified, use it.
  23563. if test "x${SS7_DIR}" != "x"; then
  23564. SS7_INCLUDE="-I${SS7_DIR}/include"
  23565. fi
  23566. SS7_INCLUDE="${SS7_INCLUDE} "
  23567. if test "xlibss7.h" = "x" ; then # no header, assume found
  23568. SS7_HEADER_FOUND="1"
  23569. else # check for the header
  23570. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23571. CPPFLAGS="${CPPFLAGS} ${SS7_INCLUDE}"
  23572. ac_fn_c_check_header_mongrel "$LINENO" "libss7.h" "ac_cv_header_libss7_h" "$ac_includes_default"
  23573. if test "x$ac_cv_header_libss7_h" = xyes; then :
  23574. SS7_HEADER_FOUND=1
  23575. else
  23576. SS7_HEADER_FOUND=0
  23577. fi
  23578. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23579. fi
  23580. if test "x${SS7_HEADER_FOUND}" = "x0" ; then
  23581. SS7_LIB=""
  23582. SS7_INCLUDE=""
  23583. else
  23584. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23585. SS7_LIB=""
  23586. fi
  23587. PBX_SS7=1
  23588. cat >>confdefs.h <<_ACEOF
  23589. #define HAVE_SS7 1
  23590. _ACEOF
  23591. fi
  23592. fi
  23593. fi
  23594. if test "x${PBX_OPENR2}" != "x1" -a "${USE_OPENR2}" != "no"; then
  23595. pbxlibdir=""
  23596. # if --with-OPENR2=DIR has been specified, use it.
  23597. if test "x${OPENR2_DIR}" != "x"; then
  23598. if test -d ${OPENR2_DIR}/lib; then
  23599. pbxlibdir="-L${OPENR2_DIR}/lib"
  23600. else
  23601. pbxlibdir="-L${OPENR2_DIR}"
  23602. fi
  23603. fi
  23604. pbxfuncname="openr2_chan_new"
  23605. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23606. AST_OPENR2_FOUND=yes
  23607. else
  23608. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23609. CFLAGS="${CFLAGS} "
  23610. as_ac_Lib=`$as_echo "ac_cv_lib_openr2_${pbxfuncname}" | $as_tr_sh`
  23611. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lopenr2" >&5
  23612. $as_echo_n "checking for ${pbxfuncname} in -lopenr2... " >&6; }
  23613. if eval \${$as_ac_Lib+:} false; then :
  23614. $as_echo_n "(cached) " >&6
  23615. else
  23616. ac_check_lib_save_LIBS=$LIBS
  23617. LIBS="-lopenr2 ${pbxlibdir} $LIBS"
  23618. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23619. /* end confdefs.h. */
  23620. /* Override any GCC internal prototype to avoid an error.
  23621. Use char because int might match the return type of a GCC
  23622. builtin and then its argument prototype would still apply. */
  23623. #ifdef __cplusplus
  23624. extern "C"
  23625. #endif
  23626. char ${pbxfuncname} ();
  23627. int
  23628. main ()
  23629. {
  23630. return ${pbxfuncname} ();
  23631. ;
  23632. return 0;
  23633. }
  23634. _ACEOF
  23635. if ac_fn_c_try_link "$LINENO"; then :
  23636. eval "$as_ac_Lib=yes"
  23637. else
  23638. eval "$as_ac_Lib=no"
  23639. fi
  23640. rm -f core conftest.err conftest.$ac_objext \
  23641. conftest$ac_exeext conftest.$ac_ext
  23642. LIBS=$ac_check_lib_save_LIBS
  23643. fi
  23644. eval ac_res=\$$as_ac_Lib
  23645. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23646. $as_echo "$ac_res" >&6; }
  23647. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23648. AST_OPENR2_FOUND=yes
  23649. else
  23650. AST_OPENR2_FOUND=no
  23651. fi
  23652. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23653. fi
  23654. # now check for the header.
  23655. if test "${AST_OPENR2_FOUND}" = "yes"; then
  23656. OPENR2_LIB="${pbxlibdir} -lopenr2 "
  23657. # if --with-OPENR2=DIR has been specified, use it.
  23658. if test "x${OPENR2_DIR}" != "x"; then
  23659. OPENR2_INCLUDE="-I${OPENR2_DIR}/include"
  23660. fi
  23661. OPENR2_INCLUDE="${OPENR2_INCLUDE} "
  23662. if test "xopenr2.h" = "x" ; then # no header, assume found
  23663. OPENR2_HEADER_FOUND="1"
  23664. else # check for the header
  23665. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23666. CPPFLAGS="${CPPFLAGS} ${OPENR2_INCLUDE}"
  23667. ac_fn_c_check_header_mongrel "$LINENO" "openr2.h" "ac_cv_header_openr2_h" "$ac_includes_default"
  23668. if test "x$ac_cv_header_openr2_h" = xyes; then :
  23669. OPENR2_HEADER_FOUND=1
  23670. else
  23671. OPENR2_HEADER_FOUND=0
  23672. fi
  23673. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23674. fi
  23675. if test "x${OPENR2_HEADER_FOUND}" = "x0" ; then
  23676. OPENR2_LIB=""
  23677. OPENR2_INCLUDE=""
  23678. else
  23679. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23680. OPENR2_LIB=""
  23681. fi
  23682. PBX_OPENR2=1
  23683. cat >>confdefs.h <<_ACEOF
  23684. #define HAVE_OPENR2 1
  23685. _ACEOF
  23686. fi
  23687. fi
  23688. fi
  23689. if test "x${PBX_OPUS}" != "x1" -a "${USE_OPUS}" != "no"; then
  23690. pbxlibdir=""
  23691. # if --with-OPUS=DIR has been specified, use it.
  23692. if test "x${OPUS_DIR}" != "x"; then
  23693. if test -d ${OPUS_DIR}/lib; then
  23694. pbxlibdir="-L${OPUS_DIR}/lib"
  23695. else
  23696. pbxlibdir="-L${OPUS_DIR}"
  23697. fi
  23698. fi
  23699. pbxfuncname="opus_encoder_create"
  23700. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  23701. AST_OPUS_FOUND=yes
  23702. else
  23703. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  23704. CFLAGS="${CFLAGS} "
  23705. as_ac_Lib=`$as_echo "ac_cv_lib_opus_${pbxfuncname}" | $as_tr_sh`
  23706. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lopus" >&5
  23707. $as_echo_n "checking for ${pbxfuncname} in -lopus... " >&6; }
  23708. if eval \${$as_ac_Lib+:} false; then :
  23709. $as_echo_n "(cached) " >&6
  23710. else
  23711. ac_check_lib_save_LIBS=$LIBS
  23712. LIBS="-lopus ${pbxlibdir} $LIBS"
  23713. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  23714. /* end confdefs.h. */
  23715. /* Override any GCC internal prototype to avoid an error.
  23716. Use char because int might match the return type of a GCC
  23717. builtin and then its argument prototype would still apply. */
  23718. #ifdef __cplusplus
  23719. extern "C"
  23720. #endif
  23721. char ${pbxfuncname} ();
  23722. int
  23723. main ()
  23724. {
  23725. return ${pbxfuncname} ();
  23726. ;
  23727. return 0;
  23728. }
  23729. _ACEOF
  23730. if ac_fn_c_try_link "$LINENO"; then :
  23731. eval "$as_ac_Lib=yes"
  23732. else
  23733. eval "$as_ac_Lib=no"
  23734. fi
  23735. rm -f core conftest.err conftest.$ac_objext \
  23736. conftest$ac_exeext conftest.$ac_ext
  23737. LIBS=$ac_check_lib_save_LIBS
  23738. fi
  23739. eval ac_res=\$$as_ac_Lib
  23740. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  23741. $as_echo "$ac_res" >&6; }
  23742. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  23743. AST_OPUS_FOUND=yes
  23744. else
  23745. AST_OPUS_FOUND=no
  23746. fi
  23747. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  23748. fi
  23749. # now check for the header.
  23750. if test "${AST_OPUS_FOUND}" = "yes"; then
  23751. OPUS_LIB="${pbxlibdir} -lopus "
  23752. # if --with-OPUS=DIR has been specified, use it.
  23753. if test "x${OPUS_DIR}" != "x"; then
  23754. OPUS_INCLUDE="-I${OPUS_DIR}/include"
  23755. fi
  23756. OPUS_INCLUDE="${OPUS_INCLUDE} "
  23757. if test "xopus/opus.h" = "x" ; then # no header, assume found
  23758. OPUS_HEADER_FOUND="1"
  23759. else # check for the header
  23760. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  23761. CPPFLAGS="${CPPFLAGS} ${OPUS_INCLUDE}"
  23762. ac_fn_c_check_header_mongrel "$LINENO" "opus/opus.h" "ac_cv_header_opus_opus_h" "$ac_includes_default"
  23763. if test "x$ac_cv_header_opus_opus_h" = xyes; then :
  23764. OPUS_HEADER_FOUND=1
  23765. else
  23766. OPUS_HEADER_FOUND=0
  23767. fi
  23768. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  23769. fi
  23770. if test "x${OPUS_HEADER_FOUND}" = "x0" ; then
  23771. OPUS_LIB=""
  23772. OPUS_INCLUDE=""
  23773. else
  23774. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  23775. OPUS_LIB=""
  23776. fi
  23777. PBX_OPUS=1
  23778. cat >>confdefs.h <<_ACEOF
  23779. #define HAVE_OPUS 1
  23780. _ACEOF
  23781. fi
  23782. fi
  23783. fi
  23784. if test "${USE_PWLIB}" != "no"; then
  23785. if test -n "${PWLIB_DIR}"; then
  23786. PWLIBDIR="${PWLIB_DIR}"
  23787. fi
  23788. PWLIB_INCDIR=
  23789. PWLIB_LIBDIR=
  23790. ac_ext=cpp
  23791. ac_cpp='$CXXCPP $CPPFLAGS'
  23792. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23793. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23794. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  23795. if test "${PWLIBDIR:-unset}" != "unset" ; then
  23796. as_ac_Header=`$as_echo "ac_cv_header_${PWLIBDIR}/version.h" | $as_tr_sh`
  23797. ac_fn_cxx_check_header_mongrel "$LINENO" "${PWLIBDIR}/version.h" "$as_ac_Header" "$ac_includes_default"
  23798. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23799. HAS_PWLIB=1
  23800. fi
  23801. fi
  23802. if test "${HAS_PWLIB:-unset}" = "unset" ; then
  23803. if test "${OPENH323DIR:-unset}" != "unset"; then
  23804. as_ac_Header=`$as_echo "ac_cv_header_${OPENH323DIR}/../pwlib/version.h" | $as_tr_sh`
  23805. ac_fn_cxx_check_header_mongrel "$LINENO" "${OPENH323DIR}/../pwlib/version.h" "$as_ac_Header" "$ac_includes_default"
  23806. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23807. HAS_PWLIB=1
  23808. fi
  23809. fi
  23810. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23811. PWLIBDIR="${OPENH323DIR}/../pwlib"
  23812. else
  23813. as_ac_Header=`$as_echo "ac_cv_header_${HOME}/pwlib/include/ptlib.h" | $as_tr_sh`
  23814. ac_fn_cxx_check_header_mongrel "$LINENO" "${HOME}/pwlib/include/ptlib.h" "$as_ac_Header" "$ac_includes_default"
  23815. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  23816. HAS_PWLIB=1
  23817. fi
  23818. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23819. PWLIBDIR="${HOME}/pwlib"
  23820. else
  23821. ac_fn_cxx_check_header_mongrel "$LINENO" "/usr/local/include/ptlib.h" "ac_cv_header__usr_local_include_ptlib_h" "$ac_includes_default"
  23822. if test "x$ac_cv_header__usr_local_include_ptlib_h" = xyes; then :
  23823. HAS_PWLIB=1
  23824. fi
  23825. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23826. # Extract the first word of "ptlib-config", so it can be a program name with args.
  23827. set dummy ptlib-config; ac_word=$2
  23828. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  23829. $as_echo_n "checking for $ac_word... " >&6; }
  23830. if ${ac_cv_path_PTLIB_CONFIG+:} false; then :
  23831. $as_echo_n "(cached) " >&6
  23832. else
  23833. case $PTLIB_CONFIG in
  23834. [\\/]* | ?:[\\/]*)
  23835. ac_cv_path_PTLIB_CONFIG="$PTLIB_CONFIG" # Let the user override the test with a path.
  23836. ;;
  23837. *)
  23838. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  23839. for as_dir in /usr/local/bin$PATH_SEPARATOR/usr/local/share/pwlib/make
  23840. do
  23841. IFS=$as_save_IFS
  23842. test -z "$as_dir" && as_dir=.
  23843. for ac_exec_ext in '' $ac_executable_extensions; do
  23844. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  23845. ac_cv_path_PTLIB_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  23846. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  23847. break 2
  23848. fi
  23849. done
  23850. done
  23851. IFS=$as_save_IFS
  23852. ;;
  23853. esac
  23854. fi
  23855. PTLIB_CONFIG=$ac_cv_path_PTLIB_CONFIG
  23856. if test -n "$PTLIB_CONFIG"; then
  23857. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTLIB_CONFIG" >&5
  23858. $as_echo "$PTLIB_CONFIG" >&6; }
  23859. else
  23860. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23861. $as_echo "no" >&6; }
  23862. fi
  23863. PWLIB_INCDIR="/usr/local/include"
  23864. PWLIB_LIBDIR=`${PTLIB_CONFIG} --pwlibdir 2>/dev/null`
  23865. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23866. PWLIB_LIBDIR=`${PTLIB_CONFIG} --ptlibdir 2>/dev/null`
  23867. fi
  23868. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23869. if test "x$LIB64" != "x"; then
  23870. PWLIB_LIBDIR="/usr/local/lib64"
  23871. else
  23872. PWLIB_LIBDIR="/usr/local/lib"
  23873. fi
  23874. fi
  23875. PWLIB_LIB=`${PTLIB_CONFIG} --ldflags --libs`
  23876. PWLIB_LIB="-L${PWLIB_LIBDIR} `echo ${PWLIB_LIB}`"
  23877. else
  23878. ac_fn_cxx_check_header_mongrel "$LINENO" "/usr/include/ptlib.h" "ac_cv_header__usr_include_ptlib_h" "$ac_includes_default"
  23879. if test "x$ac_cv_header__usr_include_ptlib_h" = xyes; then :
  23880. HAS_PWLIB=1
  23881. fi
  23882. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23883. # Extract the first word of "ptlib-config", so it can be a program name with args.
  23884. set dummy ptlib-config; ac_word=$2
  23885. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  23886. $as_echo_n "checking for $ac_word... " >&6; }
  23887. if ${ac_cv_path_PTLIB_CONFIG+:} false; then :
  23888. $as_echo_n "(cached) " >&6
  23889. else
  23890. case $PTLIB_CONFIG in
  23891. [\\/]* | ?:[\\/]*)
  23892. ac_cv_path_PTLIB_CONFIG="$PTLIB_CONFIG" # Let the user override the test with a path.
  23893. ;;
  23894. *)
  23895. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  23896. for as_dir in /usr/bin$PATH_SEPARATOR/usr/share/pwlib/make
  23897. do
  23898. IFS=$as_save_IFS
  23899. test -z "$as_dir" && as_dir=.
  23900. for ac_exec_ext in '' $ac_executable_extensions; do
  23901. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  23902. ac_cv_path_PTLIB_CONFIG="$as_dir/$ac_word$ac_exec_ext"
  23903. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  23904. break 2
  23905. fi
  23906. done
  23907. done
  23908. IFS=$as_save_IFS
  23909. ;;
  23910. esac
  23911. fi
  23912. PTLIB_CONFIG=$ac_cv_path_PTLIB_CONFIG
  23913. if test -n "$PTLIB_CONFIG"; then
  23914. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTLIB_CONFIG" >&5
  23915. $as_echo "$PTLIB_CONFIG" >&6; }
  23916. else
  23917. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  23918. $as_echo "no" >&6; }
  23919. fi
  23920. PWLIB_INCDIR="/usr/include"
  23921. PWLIB_LIBDIR=`${PTLIB_CONFIG} --pwlibdir 2>/dev/null`
  23922. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23923. PWLIB_LIBDIR=`${PTLIB_CONFIG} --ptlibdir 2>/dev/null`
  23924. fi
  23925. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23926. if test "x$LIB64" != "x"; then
  23927. PWLIB_LIBDIR="/usr/lib64"
  23928. else
  23929. PWLIB_LIBDIR="/usr/lib"
  23930. fi
  23931. fi
  23932. PWLIB_LIB=`${PTLIB_CONFIG} --ldflags --libs`
  23933. PWLIB_LIB="-L${PWLIB_LIBDIR} `echo ${PWLIB_LIB}`"
  23934. fi
  23935. fi
  23936. fi
  23937. fi
  23938. fi
  23939. #if test "${HAS_PWLIB:-unset}" = "unset" ; then
  23940. # echo "Cannot find pwlib - please install or set PWLIBDIR and try again"
  23941. # exit
  23942. #fi
  23943. if test "${HAS_PWLIB:-unset}" != "unset" ; then
  23944. if test "${PWLIBDIR:-unset}" = "unset" ; then
  23945. if test "${PTLIB_CONFIG:-unset}" != "unset" ; then
  23946. PWLIBDIR=`$PTLIB_CONFIG --prefix`
  23947. else
  23948. echo "Cannot find ptlib-config - please install and try again"
  23949. exit
  23950. fi
  23951. fi
  23952. if test "x$PWLIBDIR" = "x/usr" -o "x$PWLIBDIR" = "x/usr/"; then
  23953. PWLIBDIR="/usr/share/pwlib"
  23954. PWLIB_INCDIR="/usr/include"
  23955. if test "x$LIB64" != "x"; then
  23956. PWLIB_LIBDIR="/usr/lib64"
  23957. else
  23958. PWLIB_LIBDIR="/usr/lib"
  23959. fi
  23960. fi
  23961. if test "x$PWLIBDIR" = "x/usr/local" -o "x$PWLIBDIR" = "x/usr/"; then
  23962. PWLIBDIR="/usr/local/share/pwlib"
  23963. PWLIB_INCDIR="/usr/local/include"
  23964. if test "x$LIB64" != "x"; then
  23965. PWLIB_LIBDIR="/usr/local/lib64"
  23966. else
  23967. PWLIB_LIBDIR="/usr/local/lib"
  23968. fi
  23969. fi
  23970. if test "${PWLIB_INCDIR:-unset}" = "unset"; then
  23971. PWLIB_INCDIR="${PWLIBDIR}/include"
  23972. fi
  23973. if test "${PWLIB_LIBDIR:-unset}" = "unset"; then
  23974. PWLIB_LIBDIR="${PWLIBDIR}/lib"
  23975. fi
  23976. fi
  23977. ac_ext=c
  23978. ac_cpp='$CPP $CPPFLAGS'
  23979. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  23980. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  23981. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  23982. if test "xP[WT]LIB_VERSION" != "x"; then
  23983. VNAME="P[WT]LIB_VERSION"
  23984. else
  23985. VNAME="PWLIB_VERSION"
  23986. fi
  23987. if test "${HAS_PWLIB:-unset}" != "unset"; then
  23988. PWLIB_VERSION=`grep "$VNAME \"" ${PWLIB_INCDIR}/ptbuildopts.h | sed -e 's/[[:space:]]\{1,\}/ /g' | cut -f3 -d ' ' | sed -e 's/"//g'`
  23989. PWLIB_MAJOR_VERSION=`echo ${PWLIB_VERSION} | cut -f1 -d.`
  23990. PWLIB_MINOR_VERSION=`echo ${PWLIB_VERSION} | cut -f2 -d.`
  23991. PWLIB_BUILD_NUMBER=`echo ${PWLIB_VERSION} | cut -f3 -d.`
  23992. PWLIB_VER=$((${PWLIB_MAJOR_VERSION}*10000+${PWLIB_MINOR_VERSION}*100+${PWLIB_BUILD_NUMBER}))
  23993. PWLIB_REQ=$((1*10000+9*100+2))
  23994. if test "x" = "x"; then
  23995. PWLIB_MAX=9999999
  23996. else
  23997. PWLIB_MAX=$((*10000+*100+))
  23998. fi
  23999. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if PWLib version ${PWLIB_VERSION} is compatible with chan_h323" >&5
  24000. $as_echo_n "checking if PWLib version ${PWLIB_VERSION} is compatible with chan_h323... " >&6; }
  24001. if test ${PWLIB_VER} -lt ${PWLIB_REQ}; then
  24002. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  24003. $as_echo "no" >&6; }
  24004. unset HAS_PWLIB
  24005. else
  24006. if test ${PWLIB_VER} -gt ${PWLIB_MAX}; then
  24007. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  24008. $as_echo "no" >&6; }
  24009. unset HAS_PWLIB
  24010. else
  24011. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  24012. $as_echo "yes" >&6; }
  24013. fi
  24014. fi
  24015. fi
  24016. if test "${HAS_PWLIB:-unset}" != "unset"; then
  24017. PWLIB_OSTYPE=
  24018. case "$host_os" in
  24019. linux*) PWLIB_OSTYPE=linux ;
  24020. ;;
  24021. freebsd* ) PWLIB_OSTYPE=FreeBSD ;
  24022. ;;
  24023. openbsd* ) PWLIB_OSTYPE=OpenBSD ;
  24024. ENDLDLIBS="-lossaudio" ;
  24025. ;;
  24026. netbsd* ) PWLIB_OSTYPE=NetBSD ;
  24027. ENDLDLIBS="-lossaudio" ;
  24028. ;;
  24029. solaris* | sunos* ) PWLIB_OSTYPE=solaris ;
  24030. ;;
  24031. darwin* ) PWLIB_OSTYPE=Darwin ;
  24032. ;;
  24033. beos*) PWLIB_OSTYPE=beos ;
  24034. STDCCFLAGS="$STDCCFLAGS -D__BEOS__"
  24035. ;;
  24036. cygwin*) PWLIB_OSTYPE=cygwin ;
  24037. ;;
  24038. mingw*) PWLIB_OSTYPE=mingw ;
  24039. STDCCFLAGS="$STDCCFLAGS -mms-bitfields" ;
  24040. ENDLDLIBS="-lwinmm -lwsock32 -lsnmpapi -lmpr -lcomdlg32 -lgdi32 -lavicap32" ;
  24041. ;;
  24042. * ) PWLIB_OSTYPE="$host_os" ;
  24043. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"OS $PWLIB_OSTYPE not recognized - proceed with caution!\"" >&5
  24044. $as_echo "$as_me: WARNING: \"OS $PWLIB_OSTYPE not recognized - proceed with caution!\"" >&2;} ;
  24045. ;;
  24046. esac
  24047. PWLIB_MACHTYPE=
  24048. case "$host_cpu" in
  24049. x86 | i686 | i586 | i486 | i386 ) PWLIB_MACHTYPE=x86
  24050. ;;
  24051. x86_64) PWLIB_MACHTYPE=x86_64 ;
  24052. P_64BIT=1 ;
  24053. LIB64=1 ;
  24054. ;;
  24055. alpha | alphaev56 | alphaev6 | alphaev67 | alphaev7) PWLIB_MACHTYPE=alpha ;
  24056. P_64BIT=1 ;
  24057. ;;
  24058. sparc ) PWLIB_MACHTYPE=sparc ;
  24059. ;;
  24060. powerpc ) PWLIB_MACHTYPE=ppc ;
  24061. ;;
  24062. ppc ) PWLIB_MACHTYPE=ppc ;
  24063. ;;
  24064. powerpc64 ) PWLIB_MACHTYPE=ppc64 ;
  24065. P_64BIT=1 ;
  24066. LIB64=1 ;
  24067. ;;
  24068. ppc64 ) PWLIB_MACHTYPE=ppc64 ;
  24069. P_64BIT=1 ;
  24070. LIB64=1 ;
  24071. ;;
  24072. ia64) PWLIB_MACHTYPE=ia64 ;
  24073. P_64BIT=1 ;
  24074. ;;
  24075. s390x) PWLIB_MACHTYPE=s390x ;
  24076. P_64BIT=1 ;
  24077. LIB64=1 ;
  24078. ;;
  24079. s390) PWLIB_MACHTYPE=s390 ;
  24080. ;;
  24081. * ) PWLIB_MACHTYPE="$host_cpu";
  24082. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"CPU $PWLIB_MACHTYPE not recognized - proceed with caution!\"" >&5
  24083. $as_echo "$as_me: WARNING: \"CPU $PWLIB_MACHTYPE not recognized - proceed with caution!\"" >&2;} ;;
  24084. esac
  24085. PWLIB_PLATFORM="${PWLIB_OSTYPE}_${PWLIB_MACHTYPE}"
  24086. PLATFORM_PWLIB="pt_${PWLIB_PLATFORM}_r"
  24087. if test "${HAS_PWLIB:-unset}" != "unset"; then
  24088. { $as_echo "$as_me:${as_lineno-$LINENO}: checking PWLib installation validity" >&5
  24089. $as_echo_n "checking PWLib installation validity... " >&6; }
  24090. saved_cppflags="${CPPFLAGS}"
  24091. saved_libs="${LIBS}"
  24092. if test "${PWLIB_LIB:-unset}" != "unset"; then
  24093. LIBS="${LIBS} ${PWLIB_LIB} "
  24094. else
  24095. LIBS="${LIBS} -L${PWLIB_LIBDIR} -l${PLATFORM_PWLIB} "
  24096. fi
  24097. CPPFLAGS="${CPPFLAGS} -I${PWLIB_INCDIR} "
  24098. ac_ext=cpp
  24099. ac_cpp='$CXXCPP $CPPFLAGS'
  24100. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  24101. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  24102. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  24103. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24104. /* end confdefs.h. */
  24105. #include "ptlib.h"
  24106. int
  24107. main ()
  24108. {
  24109. int q = (int) PTime::IsDaylightSavings();
  24110. ;
  24111. return 0;
  24112. }
  24113. _ACEOF
  24114. if ac_fn_cxx_try_link "$LINENO"; then :
  24115. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  24116. $as_echo "yes" >&6; }
  24117. ac_cv_lib_PWLIB="yes"
  24118. else
  24119. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  24120. $as_echo "no" >&6; }
  24121. ac_cv_lib_PWLIB="no"
  24122. fi
  24123. rm -f core conftest.err conftest.$ac_objext \
  24124. conftest$ac_exeext conftest.$ac_ext
  24125. ac_ext=c
  24126. ac_cpp='$CPP $CPPFLAGS'
  24127. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  24128. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  24129. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  24130. LIBS="${saved_libs}"
  24131. CPPFLAGS="${saved_cppflags}"
  24132. if test "${ac_cv_lib_PWLIB}" = "yes"; then
  24133. if test "${PWLIB_LIB:-undef}" = "undef"; then
  24134. if test "${PWLIB_LIBDIR}" != "" -a "${PWLIB_LIBDIR}" != "/usr/lib"; then
  24135. PWLIB_LIB="-L${PWLIB_LIBDIR} -l${PLATFORM_PWLIB}"
  24136. else
  24137. PWLIB_LIB="-l${PLATFORM_PWLIB}"
  24138. fi
  24139. fi
  24140. if test "${PWLIB_INCDIR}" != "" -a "${PWLIB_INCDIR}" != "/usr/include"; then
  24141. PWLIB_INCLUDE="-I${PWLIB_INCDIR}"
  24142. fi
  24143. PBX_PWLIB=1
  24144. $as_echo "#define HAVE_PWLIB 1" >>confdefs.h
  24145. fi
  24146. fi
  24147. fi
  24148. fi
  24149. if test "${PBX_PWLIB}" = "1" -a "${USE_OPENH323}" != "no" ; then
  24150. if test -n "${OPENH323_DIR}"; then
  24151. OPENH323DIR="${OPENH323_DIR}"
  24152. fi
  24153. OPENH323_INCDIR=
  24154. OPENH323_LIBDIR=
  24155. ac_ext=cpp
  24156. ac_cpp='$CXXCPP $CPPFLAGS'
  24157. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  24158. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  24159. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  24160. if test "${OPENH323DIR:-unset}" != "unset" ; then
  24161. as_ac_Header=`$as_echo "ac_cv_header_${OPENH323DIR}/version.h" | $as_tr_sh`
  24162. ac_fn_cxx_check_header_mongrel "$LINENO" "${OPENH323DIR}/version.h" "$as_ac_Header" "$ac_includes_default"
  24163. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  24164. HAS_OPENH323=1
  24165. fi
  24166. fi
  24167. if test "${HAS_OPENH323:-unset}" = "unset" ; then
  24168. as_ac_Header=`$as_echo "ac_cv_header_${PWLIBDIR}/../openh323/version.h" | $as_tr_sh`
  24169. ac_fn_cxx_check_header_mongrel "$LINENO" "${PWLIBDIR}/../openh323/version.h" "$as_ac_Header" "$ac_includes_default"
  24170. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  24171. OPENH323DIR="${PWLIBDIR}/../openh323"; HAS_OPENH323=1
  24172. fi
  24173. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  24174. OPENH323DIR="${PWLIBDIR}/../openh323"
  24175. saved_cppflags="${CPPFLAGS}"
  24176. CPPFLAGS="${CPPFLAGS} -I${PWLIB_INCDIR}/openh323 -I${PWLIB_INCDIR}"
  24177. as_ac_Header=`$as_echo "ac_cv_header_${OPENH323DIR}/include/h323.h" | $as_tr_sh`
  24178. ac_fn_cxx_check_header_compile "$LINENO" "${OPENH323DIR}/include/h323.h" "$as_ac_Header" "#include <ptlib.h>
  24179. "
  24180. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  24181. else
  24182. OPENH323_INCDIR="${PWLIB_INCDIR}/openh323"; OPENH323_LIBDIR="${PWLIB_LIBDIR}"
  24183. fi
  24184. CPPFLAGS="${saved_cppflags}"
  24185. else
  24186. saved_cppflags="${CPPFLAGS}"
  24187. CPPFLAGS="${CPPFLAGS} -I${HOME}/openh323/include -I${PWLIB_INCDIR}"
  24188. as_ac_Header=`$as_echo "ac_cv_header_${HOME}/openh323/include/h323.h" | $as_tr_sh`
  24189. ac_fn_cxx_check_header_compile "$LINENO" "${HOME}/openh323/include/h323.h" "$as_ac_Header" "#include <ptlib.h>
  24190. "
  24191. if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
  24192. HAS_OPENH323=1
  24193. fi
  24194. CPPFLAGS="${saved_cppflags}"
  24195. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  24196. OPENH323DIR="${HOME}/openh323"
  24197. else
  24198. saved_cppflags="${CPPFLAGS}"
  24199. CPPFLAGS="${CPPFLAGS} -I/usr/local/include/openh323 -I${PWLIB_INCDIR}"
  24200. 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>
  24201. "
  24202. if test "x$ac_cv_header__usr_local_include_openh323_h323_h" = xyes; then :
  24203. HAS_OPENH323=1
  24204. fi
  24205. CPPFLAGS="${saved_cppflags}"
  24206. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  24207. OPENH323DIR="/usr/local/share/openh323"
  24208. OPENH323_INCDIR="/usr/local/include/openh323"
  24209. if test "x$LIB64" != "x" && test -d "/usr/local/lib64"; then
  24210. OPENH323_LIBDIR="/usr/local/lib64"
  24211. else
  24212. OPENH323_LIBDIR="/usr/local/lib"
  24213. fi
  24214. else
  24215. saved_cppflags="${CPPFLAGS}"
  24216. CPPFLAGS="${CPPFLAGS} -I/usr/include/openh323 -I${PWLIB_INCDIR}"
  24217. ac_fn_cxx_check_header_compile "$LINENO" "/usr/include/openh323/h323.h" "ac_cv_header__usr_include_openh323_h323_h" "#include <ptlib.h>
  24218. "
  24219. if test "x$ac_cv_header__usr_include_openh323_h323_h" = xyes; then :
  24220. HAS_OPENH323=1
  24221. fi
  24222. CPPFLAGS="${saved_cppflags}"
  24223. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  24224. OPENH323DIR="/usr/share/openh323"
  24225. OPENH323_INCDIR="/usr/include/openh323"
  24226. if test "x$LIB64" != "x" && test -d "/usr/local/lib64"; then
  24227. OPENH323_LIBDIR="/usr/lib64"
  24228. else
  24229. OPENH323_LIBDIR="/usr/lib"
  24230. fi
  24231. fi
  24232. fi
  24233. fi
  24234. fi
  24235. fi
  24236. if test "${HAS_OPENH323:-unset}" != "unset" ; then
  24237. if test "${OPENH323_INCDIR:-unset}" = "unset"; then
  24238. OPENH323_INCDIR="${OPENH323DIR}/include"
  24239. fi
  24240. if test "${OPENH323_LIBDIR:-unset}" = "unset"; then
  24241. OPENH323_LIBDIR="${OPENH323DIR}/lib"
  24242. fi
  24243. OPENH323_LIBDIR="`cd ${OPENH323_LIBDIR}; pwd`"
  24244. OPENH323_INCDIR="`cd ${OPENH323_INCDIR}; pwd`"
  24245. OPENH323DIR="`cd ${OPENH323DIR}; pwd`"
  24246. fi
  24247. ac_ext=c
  24248. ac_cpp='$CPP $CPPFLAGS'
  24249. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  24250. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  24251. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  24252. if test "x" != "x"; then
  24253. VNAME=""
  24254. else
  24255. VNAME="OPENH323_VERSION"
  24256. fi
  24257. if test "${HAS_OPENH323:-unset}" != "unset"; then
  24258. OPENH323_VERSION=`grep "$VNAME \"" ${OPENH323_INCDIR}/openh323buildopts.h | sed -e 's/[[:space:]]\{1,\}/ /g' | cut -f3 -d ' ' | sed -e 's/"//g'`
  24259. OPENH323_MAJOR_VERSION=`echo ${OPENH323_VERSION} | cut -f1 -d.`
  24260. OPENH323_MINOR_VERSION=`echo ${OPENH323_VERSION} | cut -f2 -d.`
  24261. OPENH323_BUILD_NUMBER=`echo ${OPENH323_VERSION} | cut -f3 -d.`
  24262. OPENH323_VER=$((${OPENH323_MAJOR_VERSION}*10000+${OPENH323_MINOR_VERSION}*100+${OPENH323_BUILD_NUMBER}))
  24263. OPENH323_REQ=$((1*10000+17*100+3))
  24264. if test "x0" = "x"; then
  24265. OPENH323_MAX=9999999
  24266. else
  24267. OPENH323_MAX=$((1*10000+19*100+0))
  24268. fi
  24269. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if OpenH323 version ${OPENH323_VERSION} is compatible with chan_h323" >&5
  24270. $as_echo_n "checking if OpenH323 version ${OPENH323_VERSION} is compatible with chan_h323... " >&6; }
  24271. if test ${OPENH323_VER} -lt ${OPENH323_REQ}; then
  24272. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  24273. $as_echo "no" >&6; }
  24274. unset HAS_OPENH323
  24275. else
  24276. if test ${OPENH323_VER} -gt ${OPENH323_MAX}; then
  24277. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  24278. $as_echo "no" >&6; }
  24279. unset HAS_OPENH323
  24280. else
  24281. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  24282. $as_echo "yes" >&6; }
  24283. fi
  24284. fi
  24285. fi
  24286. if test "${HAS_OPENH323:-unset}" != "unset"; then
  24287. { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenH323 build option" >&5
  24288. $as_echo_n "checking OpenH323 build option... " >&6; }
  24289. OPENH323_SUFFIX=
  24290. prefixes="h323_${PWLIB_PLATFORM}_ h323_ openh323"
  24291. for pfx in $prefixes; do
  24292. #files=`ls -l /usr/local/lib/lib${pfx}*.so* 2>/dev/null`
  24293. files=`ls -l ${OPENH323_LIBDIR}/lib${pfx}*.so* 2>/dev/null`
  24294. if test -z "$files"; then
  24295. # check the default location
  24296. files=`ls -l /usr/local/lib/lib${pfx}*.so* 2>/dev/null`
  24297. fi
  24298. libfile=
  24299. if test -n "$files"; then
  24300. for f in $files; do
  24301. if test -f $f -a ! -L $f; then
  24302. libfile=`basename $f`
  24303. break;
  24304. fi
  24305. done
  24306. fi
  24307. if test -n "$libfile"; then
  24308. OPENH323_PREFIX=$pfx
  24309. break;
  24310. fi
  24311. done
  24312. if test "${libfile:-unset}" != "unset"; then
  24313. OPENH323_SUFFIX=`eval "echo ${libfile} | sed -e 's/lib${OPENH323_PREFIX}\([^.]*\)\..*/\1/'"`
  24314. fi
  24315. case "${OPENH323_SUFFIX}" in
  24316. n)
  24317. OPENH323_BUILD="notrace";;
  24318. r)
  24319. OPENH323_BUILD="opt";;
  24320. d)
  24321. OPENH323_BUILD="debug";;
  24322. *)
  24323. if test "${OPENH323_PREFIX:-undef}" = "openh323"; then
  24324. notrace=`eval "grep NOTRACE ${OPENH323DIR}/openh323u.mak | grep = | sed -e 's/[A-Z0-9_]*[ ]*=[ ]*//'"`
  24325. if test "x$notrace" = "x"; then
  24326. notrace="0"
  24327. fi
  24328. if test "$notrace" -ne 0; then
  24329. OPENH323_BUILD="notrace"
  24330. else
  24331. OPENH323_BUILD="opt"
  24332. fi
  24333. OPENH323_LIB="-l${OPENH323_PREFIX}"
  24334. else
  24335. OPENH323_BUILD="notrace"
  24336. fi
  24337. ;;
  24338. esac
  24339. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${OPENH323_BUILD}" >&5
  24340. $as_echo "${OPENH323_BUILD}" >&6; }
  24341. fi
  24342. PLATFORM_OPENH323="h323_${PWLIB_PLATFORM}_${OPENH323_SUFFIX}"
  24343. if test "${HAS_OPENH323:-unset}" != "unset"; then
  24344. { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenH323 installation validity" >&5
  24345. $as_echo_n "checking OpenH323 installation validity... " >&6; }
  24346. saved_cppflags="${CPPFLAGS}"
  24347. saved_libs="${LIBS}"
  24348. if test "${OPENH323_LIB:-unset}" != "unset"; then
  24349. LIBS="${LIBS} ${OPENH323_LIB} ${PWLIB_LIB}"
  24350. else
  24351. LIBS="${LIBS} -L${OPENH323_LIBDIR} -l${PLATFORM_OPENH323} ${PWLIB_LIB}"
  24352. fi
  24353. CPPFLAGS="${CPPFLAGS} -I${OPENH323_INCDIR} ${PWLIB_INCLUDE}"
  24354. ac_ext=cpp
  24355. ac_cpp='$CXXCPP $CPPFLAGS'
  24356. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  24357. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  24358. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  24359. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24360. /* end confdefs.h. */
  24361. #include "ptlib.h"
  24362. #include "h323.h"
  24363. #include "h323ep.h"
  24364. int
  24365. main ()
  24366. {
  24367. H323EndPoint ep = H323EndPoint();
  24368. ;
  24369. return 0;
  24370. }
  24371. _ACEOF
  24372. if ac_fn_cxx_try_link "$LINENO"; then :
  24373. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  24374. $as_echo "yes" >&6; }
  24375. ac_cv_lib_OPENH323="yes"
  24376. else
  24377. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  24378. $as_echo "no" >&6; }
  24379. ac_cv_lib_OPENH323="no"
  24380. fi
  24381. rm -f core conftest.err conftest.$ac_objext \
  24382. conftest$ac_exeext conftest.$ac_ext
  24383. ac_ext=c
  24384. ac_cpp='$CPP $CPPFLAGS'
  24385. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  24386. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  24387. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  24388. LIBS="${saved_libs}"
  24389. CPPFLAGS="${saved_cppflags}"
  24390. if test "${ac_cv_lib_OPENH323}" = "yes"; then
  24391. if test "${OPENH323_LIB:-undef}" = "undef"; then
  24392. if test "${OPENH323_LIBDIR}" != "" -a "${OPENH323_LIBDIR}" != "/usr/lib"; then
  24393. OPENH323_LIB="-L${OPENH323_LIBDIR} -l${PLATFORM_OPENH323}"
  24394. else
  24395. OPENH323_LIB="-l${PLATFORM_OPENH323}"
  24396. fi
  24397. fi
  24398. if test "${OPENH323_INCDIR}" != "" -a "${OPENH323_INCDIR}" != "/usr/include"; then
  24399. OPENH323_INCLUDE="-I${OPENH323_INCDIR}"
  24400. fi
  24401. PBX_OPENH323=1
  24402. $as_echo "#define HAVE_OPENH323 1" >>confdefs.h
  24403. fi
  24404. fi
  24405. fi
  24406. if test "x${PBX_LUA}" != "x1" -a "${USE_LUA}" != "no"; then
  24407. pbxlibdir=""
  24408. # if --with-LUA=DIR has been specified, use it.
  24409. if test "x${LUA_DIR}" != "x"; then
  24410. if test -d ${LUA_DIR}/lib; then
  24411. pbxlibdir="-L${LUA_DIR}/lib"
  24412. else
  24413. pbxlibdir="-L${LUA_DIR}"
  24414. fi
  24415. fi
  24416. pbxfuncname="luaL_newstate"
  24417. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24418. AST_LUA_FOUND=yes
  24419. else
  24420. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24421. CFLAGS="${CFLAGS} "
  24422. as_ac_Lib=`$as_echo "ac_cv_lib_lua5.2_${pbxfuncname}" | $as_tr_sh`
  24423. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -llua5.2" >&5
  24424. $as_echo_n "checking for ${pbxfuncname} in -llua5.2... " >&6; }
  24425. if eval \${$as_ac_Lib+:} false; then :
  24426. $as_echo_n "(cached) " >&6
  24427. else
  24428. ac_check_lib_save_LIBS=$LIBS
  24429. LIBS="-llua5.2 ${pbxlibdir} -lm $LIBS"
  24430. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24431. /* end confdefs.h. */
  24432. /* Override any GCC internal prototype to avoid an error.
  24433. Use char because int might match the return type of a GCC
  24434. builtin and then its argument prototype would still apply. */
  24435. #ifdef __cplusplus
  24436. extern "C"
  24437. #endif
  24438. char ${pbxfuncname} ();
  24439. int
  24440. main ()
  24441. {
  24442. return ${pbxfuncname} ();
  24443. ;
  24444. return 0;
  24445. }
  24446. _ACEOF
  24447. if ac_fn_c_try_link "$LINENO"; then :
  24448. eval "$as_ac_Lib=yes"
  24449. else
  24450. eval "$as_ac_Lib=no"
  24451. fi
  24452. rm -f core conftest.err conftest.$ac_objext \
  24453. conftest$ac_exeext conftest.$ac_ext
  24454. LIBS=$ac_check_lib_save_LIBS
  24455. fi
  24456. eval ac_res=\$$as_ac_Lib
  24457. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24458. $as_echo "$ac_res" >&6; }
  24459. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24460. AST_LUA_FOUND=yes
  24461. else
  24462. AST_LUA_FOUND=no
  24463. fi
  24464. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24465. fi
  24466. # now check for the header.
  24467. if test "${AST_LUA_FOUND}" = "yes"; then
  24468. LUA_LIB="${pbxlibdir} -llua5.2 -lm"
  24469. # if --with-LUA=DIR has been specified, use it.
  24470. if test "x${LUA_DIR}" != "x"; then
  24471. LUA_INCLUDE="-I${LUA_DIR}/include"
  24472. fi
  24473. LUA_INCLUDE="${LUA_INCLUDE} "
  24474. if test "xlua5.2/lua.h" = "x" ; then # no header, assume found
  24475. LUA_HEADER_FOUND="1"
  24476. else # check for the header
  24477. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24478. CPPFLAGS="${CPPFLAGS} ${LUA_INCLUDE}"
  24479. ac_fn_c_check_header_mongrel "$LINENO" "lua5.2/lua.h" "ac_cv_header_lua5_2_lua_h" "$ac_includes_default"
  24480. if test "x$ac_cv_header_lua5_2_lua_h" = xyes; then :
  24481. LUA_HEADER_FOUND=1
  24482. else
  24483. LUA_HEADER_FOUND=0
  24484. fi
  24485. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24486. fi
  24487. if test "x${LUA_HEADER_FOUND}" = "x0" ; then
  24488. LUA_LIB=""
  24489. LUA_INCLUDE=""
  24490. else
  24491. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24492. LUA_LIB=""
  24493. fi
  24494. PBX_LUA=1
  24495. cat >>confdefs.h <<_ACEOF
  24496. #define HAVE_LUA 1
  24497. _ACEOF
  24498. fi
  24499. fi
  24500. fi
  24501. if test "x${PBX_LUA}" = "x1" ; then
  24502. if test x"${LUA_DIR}" = x; then
  24503. LUA_INCLUDE="${LUA_INCLUDE} -I/usr/include/lua5.2"
  24504. else
  24505. LUA_INCLUDE="${LUA_INCLUDE} -I${LUA_DIR}/lua5.2"
  24506. fi
  24507. fi
  24508. if test "x${PBX_LUA}" != "x1" -a "${USE_LUA}" != "no"; then
  24509. pbxlibdir=""
  24510. # if --with-LUA=DIR has been specified, use it.
  24511. if test "x${LUA_DIR}" != "x"; then
  24512. if test -d ${LUA_DIR}/lib; then
  24513. pbxlibdir="-L${LUA_DIR}/lib"
  24514. else
  24515. pbxlibdir="-L${LUA_DIR}"
  24516. fi
  24517. fi
  24518. pbxfuncname="luaL_newstate"
  24519. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24520. AST_LUA_FOUND=yes
  24521. else
  24522. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24523. CFLAGS="${CFLAGS} "
  24524. as_ac_Lib=`$as_echo "ac_cv_lib_lua5.1_${pbxfuncname}" | $as_tr_sh`
  24525. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -llua5.1" >&5
  24526. $as_echo_n "checking for ${pbxfuncname} in -llua5.1... " >&6; }
  24527. if eval \${$as_ac_Lib+:} false; then :
  24528. $as_echo_n "(cached) " >&6
  24529. else
  24530. ac_check_lib_save_LIBS=$LIBS
  24531. LIBS="-llua5.1 ${pbxlibdir} -lm $LIBS"
  24532. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24533. /* end confdefs.h. */
  24534. /* Override any GCC internal prototype to avoid an error.
  24535. Use char because int might match the return type of a GCC
  24536. builtin and then its argument prototype would still apply. */
  24537. #ifdef __cplusplus
  24538. extern "C"
  24539. #endif
  24540. char ${pbxfuncname} ();
  24541. int
  24542. main ()
  24543. {
  24544. return ${pbxfuncname} ();
  24545. ;
  24546. return 0;
  24547. }
  24548. _ACEOF
  24549. if ac_fn_c_try_link "$LINENO"; then :
  24550. eval "$as_ac_Lib=yes"
  24551. else
  24552. eval "$as_ac_Lib=no"
  24553. fi
  24554. rm -f core conftest.err conftest.$ac_objext \
  24555. conftest$ac_exeext conftest.$ac_ext
  24556. LIBS=$ac_check_lib_save_LIBS
  24557. fi
  24558. eval ac_res=\$$as_ac_Lib
  24559. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24560. $as_echo "$ac_res" >&6; }
  24561. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24562. AST_LUA_FOUND=yes
  24563. else
  24564. AST_LUA_FOUND=no
  24565. fi
  24566. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24567. fi
  24568. # now check for the header.
  24569. if test "${AST_LUA_FOUND}" = "yes"; then
  24570. LUA_LIB="${pbxlibdir} -llua5.1 -lm"
  24571. # if --with-LUA=DIR has been specified, use it.
  24572. if test "x${LUA_DIR}" != "x"; then
  24573. LUA_INCLUDE="-I${LUA_DIR}/include"
  24574. fi
  24575. LUA_INCLUDE="${LUA_INCLUDE} "
  24576. if test "xlua5.1/lua.h" = "x" ; then # no header, assume found
  24577. LUA_HEADER_FOUND="1"
  24578. else # check for the header
  24579. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24580. CPPFLAGS="${CPPFLAGS} ${LUA_INCLUDE}"
  24581. ac_fn_c_check_header_mongrel "$LINENO" "lua5.1/lua.h" "ac_cv_header_lua5_1_lua_h" "$ac_includes_default"
  24582. if test "x$ac_cv_header_lua5_1_lua_h" = xyes; then :
  24583. LUA_HEADER_FOUND=1
  24584. else
  24585. LUA_HEADER_FOUND=0
  24586. fi
  24587. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24588. fi
  24589. if test "x${LUA_HEADER_FOUND}" = "x0" ; then
  24590. LUA_LIB=""
  24591. LUA_INCLUDE=""
  24592. else
  24593. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24594. LUA_LIB=""
  24595. fi
  24596. PBX_LUA=1
  24597. cat >>confdefs.h <<_ACEOF
  24598. #define HAVE_LUA 1
  24599. _ACEOF
  24600. fi
  24601. fi
  24602. fi
  24603. if test "x${PBX_LUA}" = "x1" ; then
  24604. if test x"${LUA_DIR}" = x; then
  24605. LUA_INCLUDE="${LUA_INCLUDE} -I/usr/include/lua5.1"
  24606. else
  24607. LUA_INCLUDE="${LUA_INCLUDE} -I${LUA_DIR}/lua5.1"
  24608. fi
  24609. fi
  24610. # Some distributions (like SuSE) remove the 5.1 suffix.
  24611. if test "x${PBX_LUA}" != "x1" -a "${USE_LUA}" != "no"; then
  24612. pbxlibdir=""
  24613. # if --with-LUA=DIR has been specified, use it.
  24614. if test "x${LUA_DIR}" != "x"; then
  24615. if test -d ${LUA_DIR}/lib; then
  24616. pbxlibdir="-L${LUA_DIR}/lib"
  24617. else
  24618. pbxlibdir="-L${LUA_DIR}"
  24619. fi
  24620. fi
  24621. pbxfuncname="luaL_openlib"
  24622. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24623. AST_LUA_FOUND=yes
  24624. else
  24625. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24626. CFLAGS="${CFLAGS} "
  24627. as_ac_Lib=`$as_echo "ac_cv_lib_lua_${pbxfuncname}" | $as_tr_sh`
  24628. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -llua" >&5
  24629. $as_echo_n "checking for ${pbxfuncname} in -llua... " >&6; }
  24630. if eval \${$as_ac_Lib+:} false; then :
  24631. $as_echo_n "(cached) " >&6
  24632. else
  24633. ac_check_lib_save_LIBS=$LIBS
  24634. LIBS="-llua ${pbxlibdir} -lm $LIBS"
  24635. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24636. /* end confdefs.h. */
  24637. /* Override any GCC internal prototype to avoid an error.
  24638. Use char because int might match the return type of a GCC
  24639. builtin and then its argument prototype would still apply. */
  24640. #ifdef __cplusplus
  24641. extern "C"
  24642. #endif
  24643. char ${pbxfuncname} ();
  24644. int
  24645. main ()
  24646. {
  24647. return ${pbxfuncname} ();
  24648. ;
  24649. return 0;
  24650. }
  24651. _ACEOF
  24652. if ac_fn_c_try_link "$LINENO"; then :
  24653. eval "$as_ac_Lib=yes"
  24654. else
  24655. eval "$as_ac_Lib=no"
  24656. fi
  24657. rm -f core conftest.err conftest.$ac_objext \
  24658. conftest$ac_exeext conftest.$ac_ext
  24659. LIBS=$ac_check_lib_save_LIBS
  24660. fi
  24661. eval ac_res=\$$as_ac_Lib
  24662. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24663. $as_echo "$ac_res" >&6; }
  24664. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24665. AST_LUA_FOUND=yes
  24666. else
  24667. AST_LUA_FOUND=no
  24668. fi
  24669. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24670. fi
  24671. # now check for the header.
  24672. if test "${AST_LUA_FOUND}" = "yes"; then
  24673. LUA_LIB="${pbxlibdir} -llua -lm"
  24674. # if --with-LUA=DIR has been specified, use it.
  24675. if test "x${LUA_DIR}" != "x"; then
  24676. LUA_INCLUDE="-I${LUA_DIR}/include"
  24677. fi
  24678. LUA_INCLUDE="${LUA_INCLUDE} "
  24679. if test "xlua.h" = "x" ; then # no header, assume found
  24680. LUA_HEADER_FOUND="1"
  24681. else # check for the header
  24682. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24683. CPPFLAGS="${CPPFLAGS} ${LUA_INCLUDE}"
  24684. ac_fn_c_check_header_mongrel "$LINENO" "lua.h" "ac_cv_header_lua_h" "$ac_includes_default"
  24685. if test "x$ac_cv_header_lua_h" = xyes; then :
  24686. LUA_HEADER_FOUND=1
  24687. else
  24688. LUA_HEADER_FOUND=0
  24689. fi
  24690. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24691. fi
  24692. if test "x${LUA_HEADER_FOUND}" = "x0" ; then
  24693. LUA_LIB=""
  24694. LUA_INCLUDE=""
  24695. else
  24696. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24697. LUA_LIB=""
  24698. fi
  24699. PBX_LUA=1
  24700. cat >>confdefs.h <<_ACEOF
  24701. #define HAVE_LUA 1
  24702. _ACEOF
  24703. fi
  24704. fi
  24705. fi
  24706. # Accept either RADIUS client library, their APIs are fully compatible,
  24707. # just different header filenames and different SONAMEs
  24708. if test "x${PBX_RADIUS}" != "x1" -a "${USE_RADIUS}" != "no"; then
  24709. pbxlibdir=""
  24710. # if --with-RADIUS=DIR has been specified, use it.
  24711. if test "x${RADIUS_DIR}" != "x"; then
  24712. if test -d ${RADIUS_DIR}/lib; then
  24713. pbxlibdir="-L${RADIUS_DIR}/lib"
  24714. else
  24715. pbxlibdir="-L${RADIUS_DIR}"
  24716. fi
  24717. fi
  24718. pbxfuncname="rc_read_config"
  24719. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24720. AST_RADIUS_FOUND=yes
  24721. else
  24722. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24723. CFLAGS="${CFLAGS} "
  24724. as_ac_Lib=`$as_echo "ac_cv_lib_freeradius-client_${pbxfuncname}" | $as_tr_sh`
  24725. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lfreeradius-client" >&5
  24726. $as_echo_n "checking for ${pbxfuncname} in -lfreeradius-client... " >&6; }
  24727. if eval \${$as_ac_Lib+:} false; then :
  24728. $as_echo_n "(cached) " >&6
  24729. else
  24730. ac_check_lib_save_LIBS=$LIBS
  24731. LIBS="-lfreeradius-client ${pbxlibdir} $LIBS"
  24732. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24733. /* end confdefs.h. */
  24734. /* Override any GCC internal prototype to avoid an error.
  24735. Use char because int might match the return type of a GCC
  24736. builtin and then its argument prototype would still apply. */
  24737. #ifdef __cplusplus
  24738. extern "C"
  24739. #endif
  24740. char ${pbxfuncname} ();
  24741. int
  24742. main ()
  24743. {
  24744. return ${pbxfuncname} ();
  24745. ;
  24746. return 0;
  24747. }
  24748. _ACEOF
  24749. if ac_fn_c_try_link "$LINENO"; then :
  24750. eval "$as_ac_Lib=yes"
  24751. else
  24752. eval "$as_ac_Lib=no"
  24753. fi
  24754. rm -f core conftest.err conftest.$ac_objext \
  24755. conftest$ac_exeext conftest.$ac_ext
  24756. LIBS=$ac_check_lib_save_LIBS
  24757. fi
  24758. eval ac_res=\$$as_ac_Lib
  24759. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24760. $as_echo "$ac_res" >&6; }
  24761. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24762. AST_RADIUS_FOUND=yes
  24763. else
  24764. AST_RADIUS_FOUND=no
  24765. fi
  24766. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24767. fi
  24768. # now check for the header.
  24769. if test "${AST_RADIUS_FOUND}" = "yes"; then
  24770. RADIUS_LIB="${pbxlibdir} -lfreeradius-client "
  24771. # if --with-RADIUS=DIR has been specified, use it.
  24772. if test "x${RADIUS_DIR}" != "x"; then
  24773. RADIUS_INCLUDE="-I${RADIUS_DIR}/include"
  24774. fi
  24775. RADIUS_INCLUDE="${RADIUS_INCLUDE} "
  24776. if test "xfreeradius-client.h" = "x" ; then # no header, assume found
  24777. RADIUS_HEADER_FOUND="1"
  24778. else # check for the header
  24779. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24780. CPPFLAGS="${CPPFLAGS} ${RADIUS_INCLUDE}"
  24781. ac_fn_c_check_header_mongrel "$LINENO" "freeradius-client.h" "ac_cv_header_freeradius_client_h" "$ac_includes_default"
  24782. if test "x$ac_cv_header_freeradius_client_h" = xyes; then :
  24783. RADIUS_HEADER_FOUND=1
  24784. else
  24785. RADIUS_HEADER_FOUND=0
  24786. fi
  24787. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24788. fi
  24789. if test "x${RADIUS_HEADER_FOUND}" = "x0" ; then
  24790. RADIUS_LIB=""
  24791. RADIUS_INCLUDE=""
  24792. else
  24793. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24794. RADIUS_LIB=""
  24795. fi
  24796. PBX_RADIUS=1
  24797. cat >>confdefs.h <<_ACEOF
  24798. #define HAVE_RADIUS 1
  24799. _ACEOF
  24800. fi
  24801. fi
  24802. fi
  24803. if test "x${PBX_RADIUS}" = "x1"; then
  24804. $as_echo "#define FREERADIUS_CLIENT /**/" >>confdefs.h
  24805. else
  24806. if test "x${PBX_RADIUS}" != "x1" -a "${USE_RADIUS}" != "no"; then
  24807. pbxlibdir=""
  24808. # if --with-RADIUS=DIR has been specified, use it.
  24809. if test "x${RADIUS_DIR}" != "x"; then
  24810. if test -d ${RADIUS_DIR}/lib; then
  24811. pbxlibdir="-L${RADIUS_DIR}/lib"
  24812. else
  24813. pbxlibdir="-L${RADIUS_DIR}"
  24814. fi
  24815. fi
  24816. pbxfuncname="rc_read_config"
  24817. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24818. AST_RADIUS_FOUND=yes
  24819. else
  24820. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24821. CFLAGS="${CFLAGS} "
  24822. as_ac_Lib=`$as_echo "ac_cv_lib_radiusclient-ng_${pbxfuncname}" | $as_tr_sh`
  24823. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lradiusclient-ng" >&5
  24824. $as_echo_n "checking for ${pbxfuncname} in -lradiusclient-ng... " >&6; }
  24825. if eval \${$as_ac_Lib+:} false; then :
  24826. $as_echo_n "(cached) " >&6
  24827. else
  24828. ac_check_lib_save_LIBS=$LIBS
  24829. LIBS="-lradiusclient-ng ${pbxlibdir} $LIBS"
  24830. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24831. /* end confdefs.h. */
  24832. /* Override any GCC internal prototype to avoid an error.
  24833. Use char because int might match the return type of a GCC
  24834. builtin and then its argument prototype would still apply. */
  24835. #ifdef __cplusplus
  24836. extern "C"
  24837. #endif
  24838. char ${pbxfuncname} ();
  24839. int
  24840. main ()
  24841. {
  24842. return ${pbxfuncname} ();
  24843. ;
  24844. return 0;
  24845. }
  24846. _ACEOF
  24847. if ac_fn_c_try_link "$LINENO"; then :
  24848. eval "$as_ac_Lib=yes"
  24849. else
  24850. eval "$as_ac_Lib=no"
  24851. fi
  24852. rm -f core conftest.err conftest.$ac_objext \
  24853. conftest$ac_exeext conftest.$ac_ext
  24854. LIBS=$ac_check_lib_save_LIBS
  24855. fi
  24856. eval ac_res=\$$as_ac_Lib
  24857. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24858. $as_echo "$ac_res" >&6; }
  24859. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24860. AST_RADIUS_FOUND=yes
  24861. else
  24862. AST_RADIUS_FOUND=no
  24863. fi
  24864. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24865. fi
  24866. # now check for the header.
  24867. if test "${AST_RADIUS_FOUND}" = "yes"; then
  24868. RADIUS_LIB="${pbxlibdir} -lradiusclient-ng "
  24869. # if --with-RADIUS=DIR has been specified, use it.
  24870. if test "x${RADIUS_DIR}" != "x"; then
  24871. RADIUS_INCLUDE="-I${RADIUS_DIR}/include"
  24872. fi
  24873. RADIUS_INCLUDE="${RADIUS_INCLUDE} "
  24874. if test "xradiusclient-ng.h" = "x" ; then # no header, assume found
  24875. RADIUS_HEADER_FOUND="1"
  24876. else # check for the header
  24877. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24878. CPPFLAGS="${CPPFLAGS} ${RADIUS_INCLUDE}"
  24879. ac_fn_c_check_header_mongrel "$LINENO" "radiusclient-ng.h" "ac_cv_header_radiusclient_ng_h" "$ac_includes_default"
  24880. if test "x$ac_cv_header_radiusclient_ng_h" = xyes; then :
  24881. RADIUS_HEADER_FOUND=1
  24882. else
  24883. RADIUS_HEADER_FOUND=0
  24884. fi
  24885. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24886. fi
  24887. if test "x${RADIUS_HEADER_FOUND}" = "x0" ; then
  24888. RADIUS_LIB=""
  24889. RADIUS_INCLUDE=""
  24890. else
  24891. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24892. RADIUS_LIB=""
  24893. fi
  24894. PBX_RADIUS=1
  24895. cat >>confdefs.h <<_ACEOF
  24896. #define HAVE_RADIUS 1
  24897. _ACEOF
  24898. fi
  24899. fi
  24900. fi
  24901. fi
  24902. if test "x${PBX_COROSYNC}" != "x1" -a "${USE_COROSYNC}" != "no"; then
  24903. pbxlibdir=""
  24904. # if --with-COROSYNC=DIR has been specified, use it.
  24905. if test "x${COROSYNC_DIR}" != "x"; then
  24906. if test -d ${COROSYNC_DIR}/lib; then
  24907. pbxlibdir="-L${COROSYNC_DIR}/lib"
  24908. else
  24909. pbxlibdir="-L${COROSYNC_DIR}"
  24910. fi
  24911. fi
  24912. pbxfuncname="cpg_join"
  24913. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  24914. AST_COROSYNC_FOUND=yes
  24915. else
  24916. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  24917. CFLAGS="${CFLAGS} "
  24918. as_ac_Lib=`$as_echo "ac_cv_lib_cpg_${pbxfuncname}" | $as_tr_sh`
  24919. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcpg" >&5
  24920. $as_echo_n "checking for ${pbxfuncname} in -lcpg... " >&6; }
  24921. if eval \${$as_ac_Lib+:} false; then :
  24922. $as_echo_n "(cached) " >&6
  24923. else
  24924. ac_check_lib_save_LIBS=$LIBS
  24925. LIBS="-lcpg ${pbxlibdir} -lcfg $LIBS"
  24926. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  24927. /* end confdefs.h. */
  24928. /* Override any GCC internal prototype to avoid an error.
  24929. Use char because int might match the return type of a GCC
  24930. builtin and then its argument prototype would still apply. */
  24931. #ifdef __cplusplus
  24932. extern "C"
  24933. #endif
  24934. char ${pbxfuncname} ();
  24935. int
  24936. main ()
  24937. {
  24938. return ${pbxfuncname} ();
  24939. ;
  24940. return 0;
  24941. }
  24942. _ACEOF
  24943. if ac_fn_c_try_link "$LINENO"; then :
  24944. eval "$as_ac_Lib=yes"
  24945. else
  24946. eval "$as_ac_Lib=no"
  24947. fi
  24948. rm -f core conftest.err conftest.$ac_objext \
  24949. conftest$ac_exeext conftest.$ac_ext
  24950. LIBS=$ac_check_lib_save_LIBS
  24951. fi
  24952. eval ac_res=\$$as_ac_Lib
  24953. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  24954. $as_echo "$ac_res" >&6; }
  24955. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  24956. AST_COROSYNC_FOUND=yes
  24957. else
  24958. AST_COROSYNC_FOUND=no
  24959. fi
  24960. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  24961. fi
  24962. # now check for the header.
  24963. if test "${AST_COROSYNC_FOUND}" = "yes"; then
  24964. COROSYNC_LIB="${pbxlibdir} -lcpg -lcfg"
  24965. # if --with-COROSYNC=DIR has been specified, use it.
  24966. if test "x${COROSYNC_DIR}" != "x"; then
  24967. COROSYNC_INCLUDE="-I${COROSYNC_DIR}/include"
  24968. fi
  24969. COROSYNC_INCLUDE="${COROSYNC_INCLUDE} "
  24970. if test "xcorosync/cpg.h" = "x" ; then # no header, assume found
  24971. COROSYNC_HEADER_FOUND="1"
  24972. else # check for the header
  24973. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  24974. CPPFLAGS="${CPPFLAGS} ${COROSYNC_INCLUDE}"
  24975. ac_fn_c_check_header_mongrel "$LINENO" "corosync/cpg.h" "ac_cv_header_corosync_cpg_h" "$ac_includes_default"
  24976. if test "x$ac_cv_header_corosync_cpg_h" = xyes; then :
  24977. COROSYNC_HEADER_FOUND=1
  24978. else
  24979. COROSYNC_HEADER_FOUND=0
  24980. fi
  24981. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  24982. fi
  24983. if test "x${COROSYNC_HEADER_FOUND}" = "x0" ; then
  24984. COROSYNC_LIB=""
  24985. COROSYNC_INCLUDE=""
  24986. else
  24987. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  24988. COROSYNC_LIB=""
  24989. fi
  24990. PBX_COROSYNC=1
  24991. cat >>confdefs.h <<_ACEOF
  24992. #define HAVE_COROSYNC 1
  24993. _ACEOF
  24994. fi
  24995. fi
  24996. fi
  24997. if test "x${PBX_COROSYNC_CFG_STATE_TRACK}" != "x1" -a "${USE_COROSYNC_CFG_STATE_TRACK}" != "no"; then
  24998. pbxlibdir=""
  24999. # if --with-COROSYNC_CFG_STATE_TRACK=DIR has been specified, use it.
  25000. if test "x${COROSYNC_CFG_STATE_TRACK_DIR}" != "x"; then
  25001. if test -d ${COROSYNC_CFG_STATE_TRACK_DIR}/lib; then
  25002. pbxlibdir="-L${COROSYNC_CFG_STATE_TRACK_DIR}/lib"
  25003. else
  25004. pbxlibdir="-L${COROSYNC_CFG_STATE_TRACK_DIR}"
  25005. fi
  25006. fi
  25007. pbxfuncname="corosync_cfg_state_track"
  25008. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25009. AST_COROSYNC_CFG_STATE_TRACK_FOUND=yes
  25010. else
  25011. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25012. CFLAGS="${CFLAGS} "
  25013. as_ac_Lib=`$as_echo "ac_cv_lib_cfg_${pbxfuncname}" | $as_tr_sh`
  25014. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcfg" >&5
  25015. $as_echo_n "checking for ${pbxfuncname} in -lcfg... " >&6; }
  25016. if eval \${$as_ac_Lib+:} false; then :
  25017. $as_echo_n "(cached) " >&6
  25018. else
  25019. ac_check_lib_save_LIBS=$LIBS
  25020. LIBS="-lcfg ${pbxlibdir} -lcfg $LIBS"
  25021. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25022. /* end confdefs.h. */
  25023. /* Override any GCC internal prototype to avoid an error.
  25024. Use char because int might match the return type of a GCC
  25025. builtin and then its argument prototype would still apply. */
  25026. #ifdef __cplusplus
  25027. extern "C"
  25028. #endif
  25029. char ${pbxfuncname} ();
  25030. int
  25031. main ()
  25032. {
  25033. return ${pbxfuncname} ();
  25034. ;
  25035. return 0;
  25036. }
  25037. _ACEOF
  25038. if ac_fn_c_try_link "$LINENO"; then :
  25039. eval "$as_ac_Lib=yes"
  25040. else
  25041. eval "$as_ac_Lib=no"
  25042. fi
  25043. rm -f core conftest.err conftest.$ac_objext \
  25044. conftest$ac_exeext conftest.$ac_ext
  25045. LIBS=$ac_check_lib_save_LIBS
  25046. fi
  25047. eval ac_res=\$$as_ac_Lib
  25048. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25049. $as_echo "$ac_res" >&6; }
  25050. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25051. AST_COROSYNC_CFG_STATE_TRACK_FOUND=yes
  25052. else
  25053. AST_COROSYNC_CFG_STATE_TRACK_FOUND=no
  25054. fi
  25055. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25056. fi
  25057. # now check for the header.
  25058. if test "${AST_COROSYNC_CFG_STATE_TRACK_FOUND}" = "yes"; then
  25059. COROSYNC_CFG_STATE_TRACK_LIB="${pbxlibdir} -lcfg -lcfg"
  25060. # if --with-COROSYNC_CFG_STATE_TRACK=DIR has been specified, use it.
  25061. if test "x${COROSYNC_CFG_STATE_TRACK_DIR}" != "x"; then
  25062. COROSYNC_CFG_STATE_TRACK_INCLUDE="-I${COROSYNC_CFG_STATE_TRACK_DIR}/include"
  25063. fi
  25064. COROSYNC_CFG_STATE_TRACK_INCLUDE="${COROSYNC_CFG_STATE_TRACK_INCLUDE} "
  25065. if test "xcorosync/cfg.h" = "x" ; then # no header, assume found
  25066. COROSYNC_CFG_STATE_TRACK_HEADER_FOUND="1"
  25067. else # check for the header
  25068. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25069. CPPFLAGS="${CPPFLAGS} ${COROSYNC_CFG_STATE_TRACK_INCLUDE}"
  25070. ac_fn_c_check_header_mongrel "$LINENO" "corosync/cfg.h" "ac_cv_header_corosync_cfg_h" "$ac_includes_default"
  25071. if test "x$ac_cv_header_corosync_cfg_h" = xyes; then :
  25072. COROSYNC_CFG_STATE_TRACK_HEADER_FOUND=1
  25073. else
  25074. COROSYNC_CFG_STATE_TRACK_HEADER_FOUND=0
  25075. fi
  25076. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25077. fi
  25078. if test "x${COROSYNC_CFG_STATE_TRACK_HEADER_FOUND}" = "x0" ; then
  25079. COROSYNC_CFG_STATE_TRACK_LIB=""
  25080. COROSYNC_CFG_STATE_TRACK_INCLUDE=""
  25081. else
  25082. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25083. COROSYNC_CFG_STATE_TRACK_LIB=""
  25084. fi
  25085. PBX_COROSYNC_CFG_STATE_TRACK=1
  25086. cat >>confdefs.h <<_ACEOF
  25087. #define HAVE_COROSYNC_CFG_STATE_TRACK 1
  25088. _ACEOF
  25089. fi
  25090. fi
  25091. fi
  25092. if test "x${PBX_SPEEX}" != "x1" -a "${USE_SPEEX}" != "no"; then
  25093. pbxlibdir=""
  25094. # if --with-SPEEX=DIR has been specified, use it.
  25095. if test "x${SPEEX_DIR}" != "x"; then
  25096. if test -d ${SPEEX_DIR}/lib; then
  25097. pbxlibdir="-L${SPEEX_DIR}/lib"
  25098. else
  25099. pbxlibdir="-L${SPEEX_DIR}"
  25100. fi
  25101. fi
  25102. pbxfuncname="speex_encode"
  25103. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25104. AST_SPEEX_FOUND=yes
  25105. else
  25106. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25107. CFLAGS="${CFLAGS} "
  25108. as_ac_Lib=`$as_echo "ac_cv_lib_speex_${pbxfuncname}" | $as_tr_sh`
  25109. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspeex" >&5
  25110. $as_echo_n "checking for ${pbxfuncname} in -lspeex... " >&6; }
  25111. if eval \${$as_ac_Lib+:} false; then :
  25112. $as_echo_n "(cached) " >&6
  25113. else
  25114. ac_check_lib_save_LIBS=$LIBS
  25115. LIBS="-lspeex ${pbxlibdir} -lm $LIBS"
  25116. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25117. /* end confdefs.h. */
  25118. /* Override any GCC internal prototype to avoid an error.
  25119. Use char because int might match the return type of a GCC
  25120. builtin and then its argument prototype would still apply. */
  25121. #ifdef __cplusplus
  25122. extern "C"
  25123. #endif
  25124. char ${pbxfuncname} ();
  25125. int
  25126. main ()
  25127. {
  25128. return ${pbxfuncname} ();
  25129. ;
  25130. return 0;
  25131. }
  25132. _ACEOF
  25133. if ac_fn_c_try_link "$LINENO"; then :
  25134. eval "$as_ac_Lib=yes"
  25135. else
  25136. eval "$as_ac_Lib=no"
  25137. fi
  25138. rm -f core conftest.err conftest.$ac_objext \
  25139. conftest$ac_exeext conftest.$ac_ext
  25140. LIBS=$ac_check_lib_save_LIBS
  25141. fi
  25142. eval ac_res=\$$as_ac_Lib
  25143. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25144. $as_echo "$ac_res" >&6; }
  25145. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25146. AST_SPEEX_FOUND=yes
  25147. else
  25148. AST_SPEEX_FOUND=no
  25149. fi
  25150. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25151. fi
  25152. # now check for the header.
  25153. if test "${AST_SPEEX_FOUND}" = "yes"; then
  25154. SPEEX_LIB="${pbxlibdir} -lspeex -lm"
  25155. # if --with-SPEEX=DIR has been specified, use it.
  25156. if test "x${SPEEX_DIR}" != "x"; then
  25157. SPEEX_INCLUDE="-I${SPEEX_DIR}/include"
  25158. fi
  25159. SPEEX_INCLUDE="${SPEEX_INCLUDE} "
  25160. if test "xspeex/speex.h" = "x" ; then # no header, assume found
  25161. SPEEX_HEADER_FOUND="1"
  25162. else # check for the header
  25163. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25164. CPPFLAGS="${CPPFLAGS} ${SPEEX_INCLUDE}"
  25165. ac_fn_c_check_header_mongrel "$LINENO" "speex/speex.h" "ac_cv_header_speex_speex_h" "$ac_includes_default"
  25166. if test "x$ac_cv_header_speex_speex_h" = xyes; then :
  25167. SPEEX_HEADER_FOUND=1
  25168. else
  25169. SPEEX_HEADER_FOUND=0
  25170. fi
  25171. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25172. fi
  25173. if test "x${SPEEX_HEADER_FOUND}" = "x0" ; then
  25174. SPEEX_LIB=""
  25175. SPEEX_INCLUDE=""
  25176. else
  25177. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25178. SPEEX_LIB=""
  25179. fi
  25180. PBX_SPEEX=1
  25181. cat >>confdefs.h <<_ACEOF
  25182. #define HAVE_SPEEX 1
  25183. _ACEOF
  25184. fi
  25185. fi
  25186. fi
  25187. # See if the main speex library contains the preprocess functions
  25188. if test "x${PBX_SPEEX_PREPROCESS}" != "x1" -a "${USE_SPEEX_PREPROCESS}" != "no"; then
  25189. pbxlibdir=""
  25190. # if --with-SPEEX_PREPROCESS=DIR has been specified, use it.
  25191. if test "x${SPEEX_PREPROCESS_DIR}" != "x"; then
  25192. if test -d ${SPEEX_PREPROCESS_DIR}/lib; then
  25193. pbxlibdir="-L${SPEEX_PREPROCESS_DIR}/lib"
  25194. else
  25195. pbxlibdir="-L${SPEEX_PREPROCESS_DIR}"
  25196. fi
  25197. fi
  25198. pbxfuncname="speex_preprocess_ctl"
  25199. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25200. AST_SPEEX_PREPROCESS_FOUND=yes
  25201. else
  25202. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25203. CFLAGS="${CFLAGS} "
  25204. as_ac_Lib=`$as_echo "ac_cv_lib_speex_${pbxfuncname}" | $as_tr_sh`
  25205. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspeex" >&5
  25206. $as_echo_n "checking for ${pbxfuncname} in -lspeex... " >&6; }
  25207. if eval \${$as_ac_Lib+:} false; then :
  25208. $as_echo_n "(cached) " >&6
  25209. else
  25210. ac_check_lib_save_LIBS=$LIBS
  25211. LIBS="-lspeex ${pbxlibdir} -lm $LIBS"
  25212. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25213. /* end confdefs.h. */
  25214. /* Override any GCC internal prototype to avoid an error.
  25215. Use char because int might match the return type of a GCC
  25216. builtin and then its argument prototype would still apply. */
  25217. #ifdef __cplusplus
  25218. extern "C"
  25219. #endif
  25220. char ${pbxfuncname} ();
  25221. int
  25222. main ()
  25223. {
  25224. return ${pbxfuncname} ();
  25225. ;
  25226. return 0;
  25227. }
  25228. _ACEOF
  25229. if ac_fn_c_try_link "$LINENO"; then :
  25230. eval "$as_ac_Lib=yes"
  25231. else
  25232. eval "$as_ac_Lib=no"
  25233. fi
  25234. rm -f core conftest.err conftest.$ac_objext \
  25235. conftest$ac_exeext conftest.$ac_ext
  25236. LIBS=$ac_check_lib_save_LIBS
  25237. fi
  25238. eval ac_res=\$$as_ac_Lib
  25239. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25240. $as_echo "$ac_res" >&6; }
  25241. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25242. AST_SPEEX_PREPROCESS_FOUND=yes
  25243. else
  25244. AST_SPEEX_PREPROCESS_FOUND=no
  25245. fi
  25246. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25247. fi
  25248. # now check for the header.
  25249. if test "${AST_SPEEX_PREPROCESS_FOUND}" = "yes"; then
  25250. SPEEX_PREPROCESS_LIB="${pbxlibdir} -lspeex -lm"
  25251. # if --with-SPEEX_PREPROCESS=DIR has been specified, use it.
  25252. if test "x${SPEEX_PREPROCESS_DIR}" != "x"; then
  25253. SPEEX_PREPROCESS_INCLUDE="-I${SPEEX_PREPROCESS_DIR}/include"
  25254. fi
  25255. SPEEX_PREPROCESS_INCLUDE="${SPEEX_PREPROCESS_INCLUDE} "
  25256. if test "xspeex/speex.h" = "x" ; then # no header, assume found
  25257. SPEEX_PREPROCESS_HEADER_FOUND="1"
  25258. else # check for the header
  25259. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25260. CPPFLAGS="${CPPFLAGS} ${SPEEX_PREPROCESS_INCLUDE}"
  25261. ac_fn_c_check_header_mongrel "$LINENO" "speex/speex.h" "ac_cv_header_speex_speex_h" "$ac_includes_default"
  25262. if test "x$ac_cv_header_speex_speex_h" = xyes; then :
  25263. SPEEX_PREPROCESS_HEADER_FOUND=1
  25264. else
  25265. SPEEX_PREPROCESS_HEADER_FOUND=0
  25266. fi
  25267. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25268. fi
  25269. if test "x${SPEEX_PREPROCESS_HEADER_FOUND}" = "x0" ; then
  25270. SPEEX_PREPROCESS_LIB=""
  25271. SPEEX_PREPROCESS_INCLUDE=""
  25272. else
  25273. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25274. SPEEX_PREPROCESS_LIB=""
  25275. fi
  25276. PBX_SPEEX_PREPROCESS=1
  25277. cat >>confdefs.h <<_ACEOF
  25278. #define HAVE_SPEEX_PREPROCESS 1
  25279. _ACEOF
  25280. fi
  25281. fi
  25282. fi
  25283. if test "${PBX_SPEEX_PREPROCESS}" = 1; then
  25284. PBX_SPEEX_PREPROCESS=1
  25285. fi
  25286. if test "x${PBX_SPEEXDSP}" != "x1" -a "${USE_SPEEXDSP}" != "no"; then
  25287. pbxlibdir=""
  25288. # if --with-SPEEXDSP=DIR has been specified, use it.
  25289. if test "x${SPEEXDSP_DIR}" != "x"; then
  25290. if test -d ${SPEEXDSP_DIR}/lib; then
  25291. pbxlibdir="-L${SPEEXDSP_DIR}/lib"
  25292. else
  25293. pbxlibdir="-L${SPEEXDSP_DIR}"
  25294. fi
  25295. fi
  25296. pbxfuncname="speex_preprocess_ctl"
  25297. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25298. AST_SPEEXDSP_FOUND=yes
  25299. else
  25300. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25301. CFLAGS="${CFLAGS} "
  25302. as_ac_Lib=`$as_echo "ac_cv_lib_speexdsp_${pbxfuncname}" | $as_tr_sh`
  25303. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lspeexdsp" >&5
  25304. $as_echo_n "checking for ${pbxfuncname} in -lspeexdsp... " >&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="-lspeexdsp ${pbxlibdir} -lm $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_SPEEXDSP_FOUND=yes
  25341. else
  25342. AST_SPEEXDSP_FOUND=no
  25343. fi
  25344. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25345. fi
  25346. # now check for the header.
  25347. if test "${AST_SPEEXDSP_FOUND}" = "yes"; then
  25348. SPEEXDSP_LIB="${pbxlibdir} -lspeexdsp -lm"
  25349. # if --with-SPEEXDSP=DIR has been specified, use it.
  25350. if test "x${SPEEXDSP_DIR}" != "x"; then
  25351. SPEEXDSP_INCLUDE="-I${SPEEXDSP_DIR}/include"
  25352. fi
  25353. SPEEXDSP_INCLUDE="${SPEEXDSP_INCLUDE} "
  25354. if test "xspeex/speex.h" = "x" ; then # no header, assume found
  25355. SPEEXDSP_HEADER_FOUND="1"
  25356. else # check for the header
  25357. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25358. CPPFLAGS="${CPPFLAGS} ${SPEEXDSP_INCLUDE}"
  25359. ac_fn_c_check_header_mongrel "$LINENO" "speex/speex.h" "ac_cv_header_speex_speex_h" "$ac_includes_default"
  25360. if test "x$ac_cv_header_speex_speex_h" = xyes; then :
  25361. SPEEXDSP_HEADER_FOUND=1
  25362. else
  25363. SPEEXDSP_HEADER_FOUND=0
  25364. fi
  25365. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25366. fi
  25367. if test "x${SPEEXDSP_HEADER_FOUND}" = "x0" ; then
  25368. SPEEXDSP_LIB=""
  25369. SPEEXDSP_INCLUDE=""
  25370. else
  25371. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25372. SPEEXDSP_LIB=""
  25373. fi
  25374. PBX_SPEEXDSP=1
  25375. cat >>confdefs.h <<_ACEOF
  25376. #define HAVE_SPEEXDSP 1
  25377. _ACEOF
  25378. fi
  25379. fi
  25380. fi
  25381. if test "${PBX_SPEEXDSP}" = 1; then
  25382. PBX_SPEEX_PREPROCESS=1
  25383. fi
  25384. if test "x${PBX_SQLITE}" != "x1" -a "${USE_SQLITE}" != "no"; then
  25385. pbxlibdir=""
  25386. # if --with-SQLITE=DIR has been specified, use it.
  25387. if test "x${SQLITE_DIR}" != "x"; then
  25388. if test -d ${SQLITE_DIR}/lib; then
  25389. pbxlibdir="-L${SQLITE_DIR}/lib"
  25390. else
  25391. pbxlibdir="-L${SQLITE_DIR}"
  25392. fi
  25393. fi
  25394. pbxfuncname="sqlite_exec"
  25395. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25396. AST_SQLITE_FOUND=yes
  25397. else
  25398. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25399. CFLAGS="${CFLAGS} "
  25400. as_ac_Lib=`$as_echo "ac_cv_lib_sqlite_${pbxfuncname}" | $as_tr_sh`
  25401. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsqlite" >&5
  25402. $as_echo_n "checking for ${pbxfuncname} in -lsqlite... " >&6; }
  25403. if eval \${$as_ac_Lib+:} false; then :
  25404. $as_echo_n "(cached) " >&6
  25405. else
  25406. ac_check_lib_save_LIBS=$LIBS
  25407. LIBS="-lsqlite ${pbxlibdir} $LIBS"
  25408. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25409. /* end confdefs.h. */
  25410. /* Override any GCC internal prototype to avoid an error.
  25411. Use char because int might match the return type of a GCC
  25412. builtin and then its argument prototype would still apply. */
  25413. #ifdef __cplusplus
  25414. extern "C"
  25415. #endif
  25416. char ${pbxfuncname} ();
  25417. int
  25418. main ()
  25419. {
  25420. return ${pbxfuncname} ();
  25421. ;
  25422. return 0;
  25423. }
  25424. _ACEOF
  25425. if ac_fn_c_try_link "$LINENO"; then :
  25426. eval "$as_ac_Lib=yes"
  25427. else
  25428. eval "$as_ac_Lib=no"
  25429. fi
  25430. rm -f core conftest.err conftest.$ac_objext \
  25431. conftest$ac_exeext conftest.$ac_ext
  25432. LIBS=$ac_check_lib_save_LIBS
  25433. fi
  25434. eval ac_res=\$$as_ac_Lib
  25435. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25436. $as_echo "$ac_res" >&6; }
  25437. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25438. AST_SQLITE_FOUND=yes
  25439. else
  25440. AST_SQLITE_FOUND=no
  25441. fi
  25442. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25443. fi
  25444. # now check for the header.
  25445. if test "${AST_SQLITE_FOUND}" = "yes"; then
  25446. SQLITE_LIB="${pbxlibdir} -lsqlite "
  25447. # if --with-SQLITE=DIR has been specified, use it.
  25448. if test "x${SQLITE_DIR}" != "x"; then
  25449. SQLITE_INCLUDE="-I${SQLITE_DIR}/include"
  25450. fi
  25451. SQLITE_INCLUDE="${SQLITE_INCLUDE} "
  25452. if test "xsqlite.h" = "x" ; then # no header, assume found
  25453. SQLITE_HEADER_FOUND="1"
  25454. else # check for the header
  25455. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25456. CPPFLAGS="${CPPFLAGS} ${SQLITE_INCLUDE}"
  25457. ac_fn_c_check_header_mongrel "$LINENO" "sqlite.h" "ac_cv_header_sqlite_h" "$ac_includes_default"
  25458. if test "x$ac_cv_header_sqlite_h" = xyes; then :
  25459. SQLITE_HEADER_FOUND=1
  25460. else
  25461. SQLITE_HEADER_FOUND=0
  25462. fi
  25463. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25464. fi
  25465. if test "x${SQLITE_HEADER_FOUND}" = "x0" ; then
  25466. SQLITE_LIB=""
  25467. SQLITE_INCLUDE=""
  25468. else
  25469. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25470. SQLITE_LIB=""
  25471. fi
  25472. PBX_SQLITE=1
  25473. cat >>confdefs.h <<_ACEOF
  25474. #define HAVE_SQLITE 1
  25475. _ACEOF
  25476. fi
  25477. fi
  25478. fi
  25479. if test "x${PBX_SQLITE3}" != "x1" -a "${USE_SQLITE3}" != "no"; then
  25480. pbxlibdir=""
  25481. # if --with-SQLITE3=DIR has been specified, use it.
  25482. if test "x${SQLITE3_DIR}" != "x"; then
  25483. if test -d ${SQLITE3_DIR}/lib; then
  25484. pbxlibdir="-L${SQLITE3_DIR}/lib"
  25485. else
  25486. pbxlibdir="-L${SQLITE3_DIR}"
  25487. fi
  25488. fi
  25489. pbxfuncname="sqlite3_open"
  25490. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25491. AST_SQLITE3_FOUND=yes
  25492. else
  25493. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25494. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  25495. as_ac_Lib=`$as_echo "ac_cv_lib_sqlite3_${pbxfuncname}" | $as_tr_sh`
  25496. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsqlite3" >&5
  25497. $as_echo_n "checking for ${pbxfuncname} in -lsqlite3... " >&6; }
  25498. if eval \${$as_ac_Lib+:} false; then :
  25499. $as_echo_n "(cached) " >&6
  25500. else
  25501. ac_check_lib_save_LIBS=$LIBS
  25502. LIBS="-lsqlite3 ${pbxlibdir} ${PTHREAD_LIBS} $LIBS"
  25503. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25504. /* end confdefs.h. */
  25505. /* Override any GCC internal prototype to avoid an error.
  25506. Use char because int might match the return type of a GCC
  25507. builtin and then its argument prototype would still apply. */
  25508. #ifdef __cplusplus
  25509. extern "C"
  25510. #endif
  25511. char ${pbxfuncname} ();
  25512. int
  25513. main ()
  25514. {
  25515. return ${pbxfuncname} ();
  25516. ;
  25517. return 0;
  25518. }
  25519. _ACEOF
  25520. if ac_fn_c_try_link "$LINENO"; then :
  25521. eval "$as_ac_Lib=yes"
  25522. else
  25523. eval "$as_ac_Lib=no"
  25524. fi
  25525. rm -f core conftest.err conftest.$ac_objext \
  25526. conftest$ac_exeext conftest.$ac_ext
  25527. LIBS=$ac_check_lib_save_LIBS
  25528. fi
  25529. eval ac_res=\$$as_ac_Lib
  25530. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25531. $as_echo "$ac_res" >&6; }
  25532. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25533. AST_SQLITE3_FOUND=yes
  25534. else
  25535. AST_SQLITE3_FOUND=no
  25536. fi
  25537. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25538. fi
  25539. # now check for the header.
  25540. if test "${AST_SQLITE3_FOUND}" = "yes"; then
  25541. SQLITE3_LIB="${pbxlibdir} -lsqlite3 ${PTHREAD_LIBS}"
  25542. # if --with-SQLITE3=DIR has been specified, use it.
  25543. if test "x${SQLITE3_DIR}" != "x"; then
  25544. SQLITE3_INCLUDE="-I${SQLITE3_DIR}/include"
  25545. fi
  25546. SQLITE3_INCLUDE="${SQLITE3_INCLUDE} ${PTHREAD_CFLAGS}"
  25547. if test "xsqlite3.h" = "x" ; then # no header, assume found
  25548. SQLITE3_HEADER_FOUND="1"
  25549. else # check for the header
  25550. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25551. CPPFLAGS="${CPPFLAGS} ${SQLITE3_INCLUDE}"
  25552. ac_fn_c_check_header_mongrel "$LINENO" "sqlite3.h" "ac_cv_header_sqlite3_h" "$ac_includes_default"
  25553. if test "x$ac_cv_header_sqlite3_h" = xyes; then :
  25554. SQLITE3_HEADER_FOUND=1
  25555. else
  25556. SQLITE3_HEADER_FOUND=0
  25557. fi
  25558. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25559. fi
  25560. if test "x${SQLITE3_HEADER_FOUND}" = "x0" ; then
  25561. SQLITE3_LIB=""
  25562. SQLITE3_INCLUDE=""
  25563. else
  25564. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25565. SQLITE3_LIB=""
  25566. fi
  25567. PBX_SQLITE3=1
  25568. cat >>confdefs.h <<_ACEOF
  25569. #define HAVE_SQLITE3 1
  25570. _ACEOF
  25571. fi
  25572. fi
  25573. fi
  25574. if test "${PBX_SQLITE3}" != 1; then
  25575. as_fn_error $? "*** Asterisk now uses SQLite3 for the internal Asterisk database." "$LINENO" 5
  25576. as_fn_error $? "*** Please install the SQLite3 development package." "$LINENO" 5
  25577. exit 1
  25578. fi
  25579. # Find crypt support
  25580. # * -lcrypt on *NIX
  25581. # * in libsystem on OS X
  25582. if test "x${PBX_LIBCRYPT}" != "x1" -a "${USE_LIBCRYPT}" != "no"; then
  25583. pbxlibdir=""
  25584. # if --with-LIBCRYPT=DIR has been specified, use it.
  25585. if test "x${LIBCRYPT_DIR}" != "x"; then
  25586. if test -d ${LIBCRYPT_DIR}/lib; then
  25587. pbxlibdir="-L${LIBCRYPT_DIR}/lib"
  25588. else
  25589. pbxlibdir="-L${LIBCRYPT_DIR}"
  25590. fi
  25591. fi
  25592. pbxfuncname="crypt"
  25593. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25594. AST_LIBCRYPT_FOUND=yes
  25595. else
  25596. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25597. CFLAGS="${CFLAGS} "
  25598. as_ac_Lib=`$as_echo "ac_cv_lib_crypt_${pbxfuncname}" | $as_tr_sh`
  25599. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcrypt" >&5
  25600. $as_echo_n "checking for ${pbxfuncname} in -lcrypt... " >&6; }
  25601. if eval \${$as_ac_Lib+:} false; then :
  25602. $as_echo_n "(cached) " >&6
  25603. else
  25604. ac_check_lib_save_LIBS=$LIBS
  25605. LIBS="-lcrypt ${pbxlibdir} $LIBS"
  25606. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25607. /* end confdefs.h. */
  25608. /* Override any GCC internal prototype to avoid an error.
  25609. Use char because int might match the return type of a GCC
  25610. builtin and then its argument prototype would still apply. */
  25611. #ifdef __cplusplus
  25612. extern "C"
  25613. #endif
  25614. char ${pbxfuncname} ();
  25615. int
  25616. main ()
  25617. {
  25618. return ${pbxfuncname} ();
  25619. ;
  25620. return 0;
  25621. }
  25622. _ACEOF
  25623. if ac_fn_c_try_link "$LINENO"; then :
  25624. eval "$as_ac_Lib=yes"
  25625. else
  25626. eval "$as_ac_Lib=no"
  25627. fi
  25628. rm -f core conftest.err conftest.$ac_objext \
  25629. conftest$ac_exeext conftest.$ac_ext
  25630. LIBS=$ac_check_lib_save_LIBS
  25631. fi
  25632. eval ac_res=\$$as_ac_Lib
  25633. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25634. $as_echo "$ac_res" >&6; }
  25635. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25636. AST_LIBCRYPT_FOUND=yes
  25637. else
  25638. AST_LIBCRYPT_FOUND=no
  25639. fi
  25640. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25641. fi
  25642. # now check for the header.
  25643. if test "${AST_LIBCRYPT_FOUND}" = "yes"; then
  25644. LIBCRYPT_LIB="${pbxlibdir} -lcrypt "
  25645. # if --with-LIBCRYPT=DIR has been specified, use it.
  25646. if test "x${LIBCRYPT_DIR}" != "x"; then
  25647. LIBCRYPT_INCLUDE="-I${LIBCRYPT_DIR}/include"
  25648. fi
  25649. LIBCRYPT_INCLUDE="${LIBCRYPT_INCLUDE} "
  25650. if test "xcrypt.h" = "x" ; then # no header, assume found
  25651. LIBCRYPT_HEADER_FOUND="1"
  25652. else # check for the header
  25653. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25654. CPPFLAGS="${CPPFLAGS} ${LIBCRYPT_INCLUDE}"
  25655. ac_fn_c_check_header_mongrel "$LINENO" "crypt.h" "ac_cv_header_crypt_h" "$ac_includes_default"
  25656. if test "x$ac_cv_header_crypt_h" = xyes; then :
  25657. LIBCRYPT_HEADER_FOUND=1
  25658. else
  25659. LIBCRYPT_HEADER_FOUND=0
  25660. fi
  25661. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25662. fi
  25663. if test "x${LIBCRYPT_HEADER_FOUND}" = "x0" ; then
  25664. LIBCRYPT_LIB=""
  25665. LIBCRYPT_INCLUDE=""
  25666. else
  25667. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25668. LIBCRYPT_LIB=""
  25669. fi
  25670. PBX_LIBCRYPT=1
  25671. cat >>confdefs.h <<_ACEOF
  25672. #define HAVE_LIBCRYPT 1
  25673. _ACEOF
  25674. fi
  25675. fi
  25676. fi
  25677. ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt"
  25678. if test "x$ac_cv_func_crypt" = xyes; then :
  25679. SYSCRYPT=true
  25680. else
  25681. SYSCRYPT=""
  25682. fi
  25683. if test "x$LIBCRYPT_LIB" != "x" ; then
  25684. CRYPT_LIB="$LIBCRYPT_LIB"
  25685. CRYPT_INCLUDE="$LIBCRYPT_INCLUDE"
  25686. $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
  25687. elif test "x$SYSCRYPT" != "x" ; then
  25688. CRYPT_LIB=""
  25689. CRYPT_INCLUDE=""
  25690. $as_echo "#define HAVE_CRYPT 1" >>confdefs.h
  25691. fi
  25692. # Find crypt_r support
  25693. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for crypt_r in -lcrypt" >&5
  25694. $as_echo_n "checking for crypt_r in -lcrypt... " >&6; }
  25695. if ${ac_cv_lib_crypt_crypt_r+:} false; then :
  25696. $as_echo_n "(cached) " >&6
  25697. else
  25698. ac_check_lib_save_LIBS=$LIBS
  25699. LIBS="-lcrypt $LIBS"
  25700. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25701. /* end confdefs.h. */
  25702. /* Override any GCC internal prototype to avoid an error.
  25703. Use char because int might match the return type of a GCC
  25704. builtin and then its argument prototype would still apply. */
  25705. #ifdef __cplusplus
  25706. extern "C"
  25707. #endif
  25708. char crypt_r ();
  25709. int
  25710. main ()
  25711. {
  25712. return crypt_r ();
  25713. ;
  25714. return 0;
  25715. }
  25716. _ACEOF
  25717. if ac_fn_c_try_link "$LINENO"; then :
  25718. ac_cv_lib_crypt_crypt_r=yes
  25719. else
  25720. ac_cv_lib_crypt_crypt_r=no
  25721. fi
  25722. rm -f core conftest.err conftest.$ac_objext \
  25723. conftest$ac_exeext conftest.$ac_ext
  25724. LIBS=$ac_check_lib_save_LIBS
  25725. fi
  25726. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt_r" >&5
  25727. $as_echo "$ac_cv_lib_crypt_crypt_r" >&6; }
  25728. if test "x$ac_cv_lib_crypt_crypt_r" = xyes; then :
  25729. $as_echo "#define HAVE_CRYPT_R 1" >>confdefs.h
  25730. fi
  25731. if test "x${PBX_CRYPTO}" != "x1" -a "${USE_CRYPTO}" != "no"; then
  25732. pbxlibdir=""
  25733. # if --with-CRYPTO=DIR has been specified, use it.
  25734. if test "x${CRYPTO_DIR}" != "x"; then
  25735. if test -d ${CRYPTO_DIR}/lib; then
  25736. pbxlibdir="-L${CRYPTO_DIR}/lib"
  25737. else
  25738. pbxlibdir="-L${CRYPTO_DIR}"
  25739. fi
  25740. fi
  25741. pbxfuncname="AES_encrypt"
  25742. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25743. AST_CRYPTO_FOUND=yes
  25744. else
  25745. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25746. CFLAGS="${CFLAGS} "
  25747. as_ac_Lib=`$as_echo "ac_cv_lib_crypto_${pbxfuncname}" | $as_tr_sh`
  25748. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lcrypto" >&5
  25749. $as_echo_n "checking for ${pbxfuncname} in -lcrypto... " >&6; }
  25750. if eval \${$as_ac_Lib+:} false; then :
  25751. $as_echo_n "(cached) " >&6
  25752. else
  25753. ac_check_lib_save_LIBS=$LIBS
  25754. LIBS="-lcrypto ${pbxlibdir} $LIBS"
  25755. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25756. /* end confdefs.h. */
  25757. /* Override any GCC internal prototype to avoid an error.
  25758. Use char because int might match the return type of a GCC
  25759. builtin and then its argument prototype would still apply. */
  25760. #ifdef __cplusplus
  25761. extern "C"
  25762. #endif
  25763. char ${pbxfuncname} ();
  25764. int
  25765. main ()
  25766. {
  25767. return ${pbxfuncname} ();
  25768. ;
  25769. return 0;
  25770. }
  25771. _ACEOF
  25772. if ac_fn_c_try_link "$LINENO"; then :
  25773. eval "$as_ac_Lib=yes"
  25774. else
  25775. eval "$as_ac_Lib=no"
  25776. fi
  25777. rm -f core conftest.err conftest.$ac_objext \
  25778. conftest$ac_exeext conftest.$ac_ext
  25779. LIBS=$ac_check_lib_save_LIBS
  25780. fi
  25781. eval ac_res=\$$as_ac_Lib
  25782. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25783. $as_echo "$ac_res" >&6; }
  25784. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25785. AST_CRYPTO_FOUND=yes
  25786. else
  25787. AST_CRYPTO_FOUND=no
  25788. fi
  25789. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25790. fi
  25791. # now check for the header.
  25792. if test "${AST_CRYPTO_FOUND}" = "yes"; then
  25793. CRYPTO_LIB="${pbxlibdir} -lcrypto "
  25794. # if --with-CRYPTO=DIR has been specified, use it.
  25795. if test "x${CRYPTO_DIR}" != "x"; then
  25796. CRYPTO_INCLUDE="-I${CRYPTO_DIR}/include"
  25797. fi
  25798. CRYPTO_INCLUDE="${CRYPTO_INCLUDE} "
  25799. if test "xopenssl/aes.h" = "x" ; then # no header, assume found
  25800. CRYPTO_HEADER_FOUND="1"
  25801. else # check for the header
  25802. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25803. CPPFLAGS="${CPPFLAGS} ${CRYPTO_INCLUDE}"
  25804. ac_fn_c_check_header_mongrel "$LINENO" "openssl/aes.h" "ac_cv_header_openssl_aes_h" "$ac_includes_default"
  25805. if test "x$ac_cv_header_openssl_aes_h" = xyes; then :
  25806. CRYPTO_HEADER_FOUND=1
  25807. else
  25808. CRYPTO_HEADER_FOUND=0
  25809. fi
  25810. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25811. fi
  25812. if test "x${CRYPTO_HEADER_FOUND}" = "x0" ; then
  25813. CRYPTO_LIB=""
  25814. CRYPTO_INCLUDE=""
  25815. else
  25816. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25817. CRYPTO_LIB=""
  25818. fi
  25819. PBX_CRYPTO=1
  25820. cat >>confdefs.h <<_ACEOF
  25821. #define HAVE_CRYPTO 1
  25822. _ACEOF
  25823. fi
  25824. fi
  25825. fi
  25826. if test "$PBX_CRYPTO" = "1";
  25827. then
  25828. if test "x${PBX_OPENSSL}" != "x1" -a "${USE_OPENSSL}" != "no"; then
  25829. pbxlibdir=""
  25830. # if --with-OPENSSL=DIR has been specified, use it.
  25831. if test "x${OPENSSL_DIR}" != "x"; then
  25832. if test -d ${OPENSSL_DIR}/lib; then
  25833. pbxlibdir="-L${OPENSSL_DIR}/lib"
  25834. else
  25835. pbxlibdir="-L${OPENSSL_DIR}"
  25836. fi
  25837. fi
  25838. pbxfuncname="SSL_connect"
  25839. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  25840. AST_OPENSSL_FOUND=yes
  25841. else
  25842. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  25843. CFLAGS="${CFLAGS} "
  25844. as_ac_Lib=`$as_echo "ac_cv_lib_ssl_${pbxfuncname}" | $as_tr_sh`
  25845. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lssl" >&5
  25846. $as_echo_n "checking for ${pbxfuncname} in -lssl... " >&6; }
  25847. if eval \${$as_ac_Lib+:} false; then :
  25848. $as_echo_n "(cached) " >&6
  25849. else
  25850. ac_check_lib_save_LIBS=$LIBS
  25851. LIBS="-lssl ${pbxlibdir} -lcrypto $LIBS"
  25852. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25853. /* end confdefs.h. */
  25854. /* Override any GCC internal prototype to avoid an error.
  25855. Use char because int might match the return type of a GCC
  25856. builtin and then its argument prototype would still apply. */
  25857. #ifdef __cplusplus
  25858. extern "C"
  25859. #endif
  25860. char ${pbxfuncname} ();
  25861. int
  25862. main ()
  25863. {
  25864. return ${pbxfuncname} ();
  25865. ;
  25866. return 0;
  25867. }
  25868. _ACEOF
  25869. if ac_fn_c_try_link "$LINENO"; then :
  25870. eval "$as_ac_Lib=yes"
  25871. else
  25872. eval "$as_ac_Lib=no"
  25873. fi
  25874. rm -f core conftest.err conftest.$ac_objext \
  25875. conftest$ac_exeext conftest.$ac_ext
  25876. LIBS=$ac_check_lib_save_LIBS
  25877. fi
  25878. eval ac_res=\$$as_ac_Lib
  25879. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  25880. $as_echo "$ac_res" >&6; }
  25881. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  25882. AST_OPENSSL_FOUND=yes
  25883. else
  25884. AST_OPENSSL_FOUND=no
  25885. fi
  25886. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  25887. fi
  25888. # now check for the header.
  25889. if test "${AST_OPENSSL_FOUND}" = "yes"; then
  25890. OPENSSL_LIB="${pbxlibdir} -lssl -lcrypto"
  25891. # if --with-OPENSSL=DIR has been specified, use it.
  25892. if test "x${OPENSSL_DIR}" != "x"; then
  25893. OPENSSL_INCLUDE="-I${OPENSSL_DIR}/include"
  25894. fi
  25895. OPENSSL_INCLUDE="${OPENSSL_INCLUDE} "
  25896. if test "xopenssl/ssl.h" = "x" ; then # no header, assume found
  25897. OPENSSL_HEADER_FOUND="1"
  25898. else # check for the header
  25899. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  25900. CPPFLAGS="${CPPFLAGS} ${OPENSSL_INCLUDE}"
  25901. ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
  25902. if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
  25903. OPENSSL_HEADER_FOUND=1
  25904. else
  25905. OPENSSL_HEADER_FOUND=0
  25906. fi
  25907. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  25908. fi
  25909. if test "x${OPENSSL_HEADER_FOUND}" = "x0" ; then
  25910. OPENSSL_LIB=""
  25911. OPENSSL_INCLUDE=""
  25912. else
  25913. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  25914. OPENSSL_LIB=""
  25915. fi
  25916. PBX_OPENSSL=1
  25917. cat >>confdefs.h <<_ACEOF
  25918. #define HAVE_OPENSSL 1
  25919. _ACEOF
  25920. fi
  25921. fi
  25922. fi
  25923. fi
  25924. if test "$PBX_OPENSSL" = "1";
  25925. then
  25926. # if OSPTK has not been checked and is not excluded
  25927. if test "x${PBX_OSPTK}" != "x1" -a "${USE_OSPTK}" != "no"; then
  25928. # if --with-osptk=DIR has been specified, use it.
  25929. if test "x${OSPTK_DIR}" != "x"; then
  25930. osptk_cflags="-I${OSPTK_DIR}/include"
  25931. osptk_ldflags="-L${OSPTK_DIR}/lib"
  25932. else
  25933. osptk_cflags=""
  25934. osptk_ldflags=""
  25935. fi
  25936. # check for the header
  25937. osptk_saved_cppflags="${CPPFLAGS}"
  25938. CPPFLAGS="${CPPFLAGS} ${osptk_cflags}"
  25939. ac_fn_c_check_header_mongrel "$LINENO" "osp/osp.h" "ac_cv_header_osp_osp_h" "$ac_includes_default"
  25940. if test "x$ac_cv_header_osp_osp_h" = xyes; then :
  25941. osptk_header_found=yes
  25942. else
  25943. osptk_header_found=no
  25944. fi
  25945. CPPFLAGS="${osptk_saved_cppflags}"
  25946. # check for the library
  25947. if test "${osptk_header_found}" = "yes"; then
  25948. osptk_extralibs="-lssl -lcrypto"
  25949. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSPPInit in -losptk" >&5
  25950. $as_echo_n "checking for OSPPInit in -losptk... " >&6; }
  25951. if ${ac_cv_lib_osptk_OSPPInit+:} false; then :
  25952. $as_echo_n "(cached) " >&6
  25953. else
  25954. ac_check_lib_save_LIBS=$LIBS
  25955. LIBS="-losptk ${osptk_ldflags} ${osptk_extralibs} $LIBS"
  25956. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  25957. /* end confdefs.h. */
  25958. /* Override any GCC internal prototype to avoid an error.
  25959. Use char because int might match the return type of a GCC
  25960. builtin and then its argument prototype would still apply. */
  25961. #ifdef __cplusplus
  25962. extern "C"
  25963. #endif
  25964. char OSPPInit ();
  25965. int
  25966. main ()
  25967. {
  25968. return OSPPInit ();
  25969. ;
  25970. return 0;
  25971. }
  25972. _ACEOF
  25973. if ac_fn_c_try_link "$LINENO"; then :
  25974. ac_cv_lib_osptk_OSPPInit=yes
  25975. else
  25976. ac_cv_lib_osptk_OSPPInit=no
  25977. fi
  25978. rm -f core conftest.err conftest.$ac_objext \
  25979. conftest$ac_exeext conftest.$ac_ext
  25980. LIBS=$ac_check_lib_save_LIBS
  25981. fi
  25982. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_osptk_OSPPInit" >&5
  25983. $as_echo "$ac_cv_lib_osptk_OSPPInit" >&6; }
  25984. if test "x$ac_cv_lib_osptk_OSPPInit" = xyes; then :
  25985. osptk_library_found=yes
  25986. else
  25987. osptk_library_found=no
  25988. fi
  25989. # check OSP Toolkit version
  25990. if test "${osptk_library_found}" = "yes"; then
  25991. { $as_echo "$as_me:${as_lineno-$LINENO}: checking if OSP Toolkit version is compatible with app_osplookup" >&5
  25992. $as_echo_n "checking if OSP Toolkit version is compatible with app_osplookup... " >&6; }
  25993. osptk_saved_cppflags="${CPPFLAGS}"
  25994. CPPFLAGS="${CPPFLAGS} ${osptk_cflags}"
  25995. if test "$cross_compiling" = yes; then :
  25996. { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
  25997. $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  25998. as_fn_error $? "cannot run test program while cross compiling
  25999. See \`config.log' for more details" "$LINENO" 5; }
  26000. else
  26001. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26002. /* end confdefs.h. */
  26003. #include <osp/osp.h>
  26004. int main(void) {
  26005. int ver = OSP_CLIENT_TOOLKIT_VERSION_MAJOR * 10000 + OSP_CLIENT_TOOLKIT_VERSION_MINOR * 100 + OSP_CLIENT_TOOLKIT_VERSION_BUGFIX;
  26006. int req = 4 * 10000 + 0 * 100 + 0;
  26007. return (ver < req) ? 1 : 0;
  26008. }
  26009. _ACEOF
  26010. if ac_fn_c_try_run "$LINENO"; then :
  26011. osptk_compatible=yes
  26012. else
  26013. osptk_compatible=no
  26014. fi
  26015. rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
  26016. conftest.$ac_objext conftest.beam conftest.$ac_ext
  26017. fi
  26018. CPPFLAGS="${osptk_saved_cppflags}"
  26019. if test "${osptk_compatible}" = "yes"; then
  26020. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26021. $as_echo "yes" >&6; }
  26022. PBX_OSPTK=1
  26023. OSPTK_INCLUDE="${osptk_cflags}"
  26024. OSPTK_LIB="${osptk_ldflags} -losptk ${osptk_extralibs}"
  26025. cat >>confdefs.h <<_ACEOF
  26026. #define HAVE_OSPTK 1
  26027. _ACEOF
  26028. else
  26029. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26030. $as_echo "no" >&6; }
  26031. fi
  26032. fi
  26033. fi
  26034. fi
  26035. if test "x${PBX_OPENSSL_SRTP}" != "x1" -a "${USE_OPENSSL_SRTP}" != "no"; then
  26036. pbxlibdir=""
  26037. # if --with-OPENSSL_SRTP=DIR has been specified, use it.
  26038. if test "x${OPENSSL_SRTP_DIR}" != "x"; then
  26039. if test -d ${OPENSSL_SRTP_DIR}/lib; then
  26040. pbxlibdir="-L${OPENSSL_SRTP_DIR}/lib"
  26041. else
  26042. pbxlibdir="-L${OPENSSL_SRTP_DIR}"
  26043. fi
  26044. fi
  26045. pbxfuncname="SSL_CTX_set_tlsext_use_srtp"
  26046. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26047. AST_OPENSSL_SRTP_FOUND=yes
  26048. else
  26049. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26050. CFLAGS="${CFLAGS} "
  26051. as_ac_Lib=`$as_echo "ac_cv_lib_ssl_${pbxfuncname}" | $as_tr_sh`
  26052. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lssl" >&5
  26053. $as_echo_n "checking for ${pbxfuncname} in -lssl... " >&6; }
  26054. if eval \${$as_ac_Lib+:} false; then :
  26055. $as_echo_n "(cached) " >&6
  26056. else
  26057. ac_check_lib_save_LIBS=$LIBS
  26058. LIBS="-lssl ${pbxlibdir} -lcrypto $LIBS"
  26059. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26060. /* end confdefs.h. */
  26061. /* Override any GCC internal prototype to avoid an error.
  26062. Use char because int might match the return type of a GCC
  26063. builtin and then its argument prototype would still apply. */
  26064. #ifdef __cplusplus
  26065. extern "C"
  26066. #endif
  26067. char ${pbxfuncname} ();
  26068. int
  26069. main ()
  26070. {
  26071. return ${pbxfuncname} ();
  26072. ;
  26073. return 0;
  26074. }
  26075. _ACEOF
  26076. if ac_fn_c_try_link "$LINENO"; then :
  26077. eval "$as_ac_Lib=yes"
  26078. else
  26079. eval "$as_ac_Lib=no"
  26080. fi
  26081. rm -f core conftest.err conftest.$ac_objext \
  26082. conftest$ac_exeext conftest.$ac_ext
  26083. LIBS=$ac_check_lib_save_LIBS
  26084. fi
  26085. eval ac_res=\$$as_ac_Lib
  26086. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26087. $as_echo "$ac_res" >&6; }
  26088. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26089. AST_OPENSSL_SRTP_FOUND=yes
  26090. else
  26091. AST_OPENSSL_SRTP_FOUND=no
  26092. fi
  26093. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26094. fi
  26095. # now check for the header.
  26096. if test "${AST_OPENSSL_SRTP_FOUND}" = "yes"; then
  26097. OPENSSL_SRTP_LIB="${pbxlibdir} -lssl -lcrypto"
  26098. # if --with-OPENSSL_SRTP=DIR has been specified, use it.
  26099. if test "x${OPENSSL_SRTP_DIR}" != "x"; then
  26100. OPENSSL_SRTP_INCLUDE="-I${OPENSSL_SRTP_DIR}/include"
  26101. fi
  26102. OPENSSL_SRTP_INCLUDE="${OPENSSL_SRTP_INCLUDE} "
  26103. if test "xopenssl/ssl.h" = "x" ; then # no header, assume found
  26104. OPENSSL_SRTP_HEADER_FOUND="1"
  26105. else # check for the header
  26106. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26107. CPPFLAGS="${CPPFLAGS} ${OPENSSL_SRTP_INCLUDE}"
  26108. ac_fn_c_check_header_mongrel "$LINENO" "openssl/ssl.h" "ac_cv_header_openssl_ssl_h" "$ac_includes_default"
  26109. if test "x$ac_cv_header_openssl_ssl_h" = xyes; then :
  26110. OPENSSL_SRTP_HEADER_FOUND=1
  26111. else
  26112. OPENSSL_SRTP_HEADER_FOUND=0
  26113. fi
  26114. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26115. fi
  26116. if test "x${OPENSSL_SRTP_HEADER_FOUND}" = "x0" ; then
  26117. OPENSSL_SRTP_LIB=""
  26118. OPENSSL_SRTP_INCLUDE=""
  26119. else
  26120. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26121. OPENSSL_SRTP_LIB=""
  26122. fi
  26123. PBX_OPENSSL_SRTP=1
  26124. cat >>confdefs.h <<_ACEOF
  26125. #define HAVE_OPENSSL_SRTP 1
  26126. _ACEOF
  26127. fi
  26128. fi
  26129. fi
  26130. fi
  26131. if test "$PBX_OPENSSL" = "1";
  26132. then
  26133. if test "x${PBX_OPENSSL_EC}" != "x1" -a "${USE_OPENSSL_EC}" != "no"; then
  26134. pbxlibdir=""
  26135. # if --with-OPENSSL_EC=DIR has been specified, use it.
  26136. if test "x${OPENSSL_EC_DIR}" != "x"; then
  26137. if test -d ${OPENSSL_EC_DIR}/lib; then
  26138. pbxlibdir="-L${OPENSSL_EC_DIR}/lib"
  26139. else
  26140. pbxlibdir="-L${OPENSSL_EC_DIR}"
  26141. fi
  26142. fi
  26143. pbxfuncname="EC_KEY_new_by_curve_name"
  26144. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26145. AST_OPENSSL_EC_FOUND=yes
  26146. else
  26147. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26148. CFLAGS="${CFLAGS} "
  26149. as_ac_Lib=`$as_echo "ac_cv_lib_ssl_${pbxfuncname}" | $as_tr_sh`
  26150. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lssl" >&5
  26151. $as_echo_n "checking for ${pbxfuncname} in -lssl... " >&6; }
  26152. if eval \${$as_ac_Lib+:} false; then :
  26153. $as_echo_n "(cached) " >&6
  26154. else
  26155. ac_check_lib_save_LIBS=$LIBS
  26156. LIBS="-lssl ${pbxlibdir} -lcrypto $LIBS"
  26157. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26158. /* end confdefs.h. */
  26159. /* Override any GCC internal prototype to avoid an error.
  26160. Use char because int might match the return type of a GCC
  26161. builtin and then its argument prototype would still apply. */
  26162. #ifdef __cplusplus
  26163. extern "C"
  26164. #endif
  26165. char ${pbxfuncname} ();
  26166. int
  26167. main ()
  26168. {
  26169. return ${pbxfuncname} ();
  26170. ;
  26171. return 0;
  26172. }
  26173. _ACEOF
  26174. if ac_fn_c_try_link "$LINENO"; then :
  26175. eval "$as_ac_Lib=yes"
  26176. else
  26177. eval "$as_ac_Lib=no"
  26178. fi
  26179. rm -f core conftest.err conftest.$ac_objext \
  26180. conftest$ac_exeext conftest.$ac_ext
  26181. LIBS=$ac_check_lib_save_LIBS
  26182. fi
  26183. eval ac_res=\$$as_ac_Lib
  26184. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26185. $as_echo "$ac_res" >&6; }
  26186. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26187. AST_OPENSSL_EC_FOUND=yes
  26188. else
  26189. AST_OPENSSL_EC_FOUND=no
  26190. fi
  26191. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26192. fi
  26193. # now check for the header.
  26194. if test "${AST_OPENSSL_EC_FOUND}" = "yes"; then
  26195. OPENSSL_EC_LIB="${pbxlibdir} -lssl -lcrypto"
  26196. # if --with-OPENSSL_EC=DIR has been specified, use it.
  26197. if test "x${OPENSSL_EC_DIR}" != "x"; then
  26198. OPENSSL_EC_INCLUDE="-I${OPENSSL_EC_DIR}/include"
  26199. fi
  26200. OPENSSL_EC_INCLUDE="${OPENSSL_EC_INCLUDE} "
  26201. if test "xopenssl/ec.h" = "x" ; then # no header, assume found
  26202. OPENSSL_EC_HEADER_FOUND="1"
  26203. else # check for the header
  26204. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26205. CPPFLAGS="${CPPFLAGS} ${OPENSSL_EC_INCLUDE}"
  26206. ac_fn_c_check_header_mongrel "$LINENO" "openssl/ec.h" "ac_cv_header_openssl_ec_h" "$ac_includes_default"
  26207. if test "x$ac_cv_header_openssl_ec_h" = xyes; then :
  26208. OPENSSL_EC_HEADER_FOUND=1
  26209. else
  26210. OPENSSL_EC_HEADER_FOUND=0
  26211. fi
  26212. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26213. fi
  26214. if test "x${OPENSSL_EC_HEADER_FOUND}" = "x0" ; then
  26215. OPENSSL_EC_LIB=""
  26216. OPENSSL_EC_INCLUDE=""
  26217. else
  26218. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26219. OPENSSL_EC_LIB=""
  26220. fi
  26221. PBX_OPENSSL_EC=1
  26222. cat >>confdefs.h <<_ACEOF
  26223. #define HAVE_OPENSSL_EC 1
  26224. _ACEOF
  26225. fi
  26226. fi
  26227. fi
  26228. fi
  26229. if test "x${PBX_SRTP}" != "x1" -a "${USE_SRTP}" != "no"; then
  26230. pbxlibdir=""
  26231. # if --with-SRTP=DIR has been specified, use it.
  26232. if test "x${SRTP_DIR}" != "x"; then
  26233. if test -d ${SRTP_DIR}/lib; then
  26234. pbxlibdir="-L${SRTP_DIR}/lib"
  26235. else
  26236. pbxlibdir="-L${SRTP_DIR}"
  26237. fi
  26238. fi
  26239. pbxfuncname="srtp_init"
  26240. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26241. AST_SRTP_FOUND=yes
  26242. else
  26243. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26244. CFLAGS="${CFLAGS} "
  26245. as_ac_Lib=`$as_echo "ac_cv_lib_srtp_${pbxfuncname}" | $as_tr_sh`
  26246. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsrtp" >&5
  26247. $as_echo_n "checking for ${pbxfuncname} in -lsrtp... " >&6; }
  26248. if eval \${$as_ac_Lib+:} false; then :
  26249. $as_echo_n "(cached) " >&6
  26250. else
  26251. ac_check_lib_save_LIBS=$LIBS
  26252. LIBS="-lsrtp ${pbxlibdir} $LIBS"
  26253. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26254. /* end confdefs.h. */
  26255. /* Override any GCC internal prototype to avoid an error.
  26256. Use char because int might match the return type of a GCC
  26257. builtin and then its argument prototype would still apply. */
  26258. #ifdef __cplusplus
  26259. extern "C"
  26260. #endif
  26261. char ${pbxfuncname} ();
  26262. int
  26263. main ()
  26264. {
  26265. return ${pbxfuncname} ();
  26266. ;
  26267. return 0;
  26268. }
  26269. _ACEOF
  26270. if ac_fn_c_try_link "$LINENO"; then :
  26271. eval "$as_ac_Lib=yes"
  26272. else
  26273. eval "$as_ac_Lib=no"
  26274. fi
  26275. rm -f core conftest.err conftest.$ac_objext \
  26276. conftest$ac_exeext conftest.$ac_ext
  26277. LIBS=$ac_check_lib_save_LIBS
  26278. fi
  26279. eval ac_res=\$$as_ac_Lib
  26280. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26281. $as_echo "$ac_res" >&6; }
  26282. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26283. AST_SRTP_FOUND=yes
  26284. else
  26285. AST_SRTP_FOUND=no
  26286. fi
  26287. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26288. fi
  26289. # now check for the header.
  26290. if test "${AST_SRTP_FOUND}" = "yes"; then
  26291. SRTP_LIB="${pbxlibdir} -lsrtp "
  26292. # if --with-SRTP=DIR has been specified, use it.
  26293. if test "x${SRTP_DIR}" != "x"; then
  26294. SRTP_INCLUDE="-I${SRTP_DIR}/include"
  26295. fi
  26296. SRTP_INCLUDE="${SRTP_INCLUDE} "
  26297. if test "xsrtp/srtp.h" = "x" ; then # no header, assume found
  26298. SRTP_HEADER_FOUND="1"
  26299. else # check for the header
  26300. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26301. CPPFLAGS="${CPPFLAGS} ${SRTP_INCLUDE}"
  26302. ac_fn_c_check_header_mongrel "$LINENO" "srtp/srtp.h" "ac_cv_header_srtp_srtp_h" "$ac_includes_default"
  26303. if test "x$ac_cv_header_srtp_srtp_h" = xyes; then :
  26304. SRTP_HEADER_FOUND=1
  26305. else
  26306. SRTP_HEADER_FOUND=0
  26307. fi
  26308. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26309. fi
  26310. if test "x${SRTP_HEADER_FOUND}" = "x0" ; then
  26311. SRTP_LIB=""
  26312. SRTP_INCLUDE=""
  26313. else
  26314. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26315. SRTP_LIB=""
  26316. fi
  26317. PBX_SRTP=1
  26318. cat >>confdefs.h <<_ACEOF
  26319. #define HAVE_SRTP 1
  26320. _ACEOF
  26321. fi
  26322. fi
  26323. fi
  26324. if test "$PBX_SRTP" = "1";
  26325. then
  26326. saved_libs="${LIBS}"
  26327. saved_ldflags="${LDFLAGS}"
  26328. saved_cflags="${CFLAGS}"
  26329. LIBS="${LIBS} ${SRTP_LIB}"
  26330. LDFLAGS="${LDFLAGS} -shared -fPIC"
  26331. CFLAGS="${CFLAGS} ${SRTP_INCLUDE}"
  26332. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the ability of -lsrtp to be linked in a shared object" >&5
  26333. $as_echo_n "checking for the ability of -lsrtp to be linked in a shared object... " >&6; }
  26334. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26335. /* end confdefs.h. */
  26336. #include <srtp/srtp.h>
  26337. int
  26338. main ()
  26339. {
  26340. srtp_init();
  26341. ;
  26342. return 0;
  26343. }
  26344. _ACEOF
  26345. if ac_fn_c_try_link "$LINENO"; then :
  26346. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26347. $as_echo "yes" >&6; }
  26348. else
  26349. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26350. $as_echo "no" >&6; }
  26351. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ***" >&5
  26352. $as_echo "$as_me: WARNING: ***" >&2;}
  26353. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** libsrtp could not be linked as a shared object." >&5
  26354. $as_echo "$as_me: WARNING: *** libsrtp could not be linked as a shared object." >&2;}
  26355. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** Try compiling libsrtp manually. Configure libsrtp" >&5
  26356. $as_echo "$as_me: WARNING: *** Try compiling libsrtp manually. Configure libsrtp" >&2;}
  26357. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** with ./configure CFLAGS=-fPIC --prefix=/usr" >&5
  26358. $as_echo "$as_me: WARNING: *** with ./configure CFLAGS=-fPIC --prefix=/usr" >&2;}
  26359. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** replacing /usr with the prefix of your choice." >&5
  26360. $as_echo "$as_me: WARNING: *** replacing /usr with the prefix of your choice." >&2;}
  26361. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** After re-installing libsrtp" >&5
  26362. $as_echo "$as_me: WARNING: *** After re-installing libsrtp" >&2;}
  26363. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** configure script." >&5
  26364. $as_echo "$as_me: WARNING: *** configure script." >&2;}
  26365. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ***" >&5
  26366. $as_echo "$as_me: WARNING: ***" >&2;}
  26367. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** If you do not need SRTP support re-run configure" >&5
  26368. $as_echo "$as_me: WARNING: *** If you do not need SRTP support re-run configure" >&2;}
  26369. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** with the --without-srtp option." >&5
  26370. $as_echo "$as_me: WARNING: *** with the --without-srtp option." >&2;}
  26371. exit 1
  26372. fi
  26373. rm -f core conftest.err conftest.$ac_objext \
  26374. conftest$ac_exeext conftest.$ac_ext
  26375. LIBS="${saved_libs}"
  26376. LDFLAGS="${saved_ldflags}"
  26377. CFLAGS="${saved_cflags}"
  26378. fi
  26379. if test "x${PBX_SRTP_SHUTDOWN}" != "x1" -a "${USE_SRTP_SHUTDOWN}" != "no"; then
  26380. pbxlibdir=""
  26381. # if --with-SRTP_SHUTDOWN=DIR has been specified, use it.
  26382. if test "x${SRTP_SHUTDOWN_DIR}" != "x"; then
  26383. if test -d ${SRTP_SHUTDOWN_DIR}/lib; then
  26384. pbxlibdir="-L${SRTP_SHUTDOWN_DIR}/lib"
  26385. else
  26386. pbxlibdir="-L${SRTP_SHUTDOWN_DIR}"
  26387. fi
  26388. fi
  26389. pbxfuncname="srtp_shutdown"
  26390. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26391. AST_SRTP_SHUTDOWN_FOUND=yes
  26392. else
  26393. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26394. CFLAGS="${CFLAGS} "
  26395. as_ac_Lib=`$as_echo "ac_cv_lib_srtp_${pbxfuncname}" | $as_tr_sh`
  26396. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsrtp" >&5
  26397. $as_echo_n "checking for ${pbxfuncname} in -lsrtp... " >&6; }
  26398. if eval \${$as_ac_Lib+:} false; then :
  26399. $as_echo_n "(cached) " >&6
  26400. else
  26401. ac_check_lib_save_LIBS=$LIBS
  26402. LIBS="-lsrtp ${pbxlibdir} $LIBS"
  26403. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26404. /* end confdefs.h. */
  26405. /* Override any GCC internal prototype to avoid an error.
  26406. Use char because int might match the return type of a GCC
  26407. builtin and then its argument prototype would still apply. */
  26408. #ifdef __cplusplus
  26409. extern "C"
  26410. #endif
  26411. char ${pbxfuncname} ();
  26412. int
  26413. main ()
  26414. {
  26415. return ${pbxfuncname} ();
  26416. ;
  26417. return 0;
  26418. }
  26419. _ACEOF
  26420. if ac_fn_c_try_link "$LINENO"; then :
  26421. eval "$as_ac_Lib=yes"
  26422. else
  26423. eval "$as_ac_Lib=no"
  26424. fi
  26425. rm -f core conftest.err conftest.$ac_objext \
  26426. conftest$ac_exeext conftest.$ac_ext
  26427. LIBS=$ac_check_lib_save_LIBS
  26428. fi
  26429. eval ac_res=\$$as_ac_Lib
  26430. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26431. $as_echo "$ac_res" >&6; }
  26432. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26433. AST_SRTP_SHUTDOWN_FOUND=yes
  26434. else
  26435. AST_SRTP_SHUTDOWN_FOUND=no
  26436. fi
  26437. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26438. fi
  26439. # now check for the header.
  26440. if test "${AST_SRTP_SHUTDOWN_FOUND}" = "yes"; then
  26441. SRTP_SHUTDOWN_LIB="${pbxlibdir} -lsrtp "
  26442. # if --with-SRTP_SHUTDOWN=DIR has been specified, use it.
  26443. if test "x${SRTP_SHUTDOWN_DIR}" != "x"; then
  26444. SRTP_SHUTDOWN_INCLUDE="-I${SRTP_SHUTDOWN_DIR}/include"
  26445. fi
  26446. SRTP_SHUTDOWN_INCLUDE="${SRTP_SHUTDOWN_INCLUDE} "
  26447. if test "xsrtp/srtp.h" = "x" ; then # no header, assume found
  26448. SRTP_SHUTDOWN_HEADER_FOUND="1"
  26449. else # check for the header
  26450. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26451. CPPFLAGS="${CPPFLAGS} ${SRTP_SHUTDOWN_INCLUDE}"
  26452. ac_fn_c_check_header_mongrel "$LINENO" "srtp/srtp.h" "ac_cv_header_srtp_srtp_h" "$ac_includes_default"
  26453. if test "x$ac_cv_header_srtp_srtp_h" = xyes; then :
  26454. SRTP_SHUTDOWN_HEADER_FOUND=1
  26455. else
  26456. SRTP_SHUTDOWN_HEADER_FOUND=0
  26457. fi
  26458. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26459. fi
  26460. if test "x${SRTP_SHUTDOWN_HEADER_FOUND}" = "x0" ; then
  26461. SRTP_SHUTDOWN_LIB=""
  26462. SRTP_SHUTDOWN_INCLUDE=""
  26463. else
  26464. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26465. SRTP_SHUTDOWN_LIB=""
  26466. fi
  26467. PBX_SRTP_SHUTDOWN=1
  26468. cat >>confdefs.h <<_ACEOF
  26469. #define HAVE_SRTP_SHUTDOWN 1
  26470. _ACEOF
  26471. fi
  26472. fi
  26473. fi
  26474. for ver in 2.0 2.2 2.4 2.6; do
  26475. if test "x${PBX_GMIME}" != "x1" -a "${USE_GMIME}" != "no"; then
  26476. pkg_failed=no
  26477. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GMIME" >&5
  26478. $as_echo_n "checking for GMIME... " >&6; }
  26479. if test -n "$GMIME_CFLAGS"; then
  26480. pkg_cv_GMIME_CFLAGS="$GMIME_CFLAGS"
  26481. elif test -n "$PKG_CONFIG"; then
  26482. if test -n "$PKG_CONFIG" && \
  26483. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gmime-\$ver\""; } >&5
  26484. ($PKG_CONFIG --exists --print-errors "gmime-$ver") 2>&5
  26485. ac_status=$?
  26486. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  26487. test $ac_status = 0; }; then
  26488. pkg_cv_GMIME_CFLAGS=`$PKG_CONFIG --cflags "gmime-$ver" 2>/dev/null`
  26489. test "x$?" != "x0" && pkg_failed=yes
  26490. else
  26491. pkg_failed=yes
  26492. fi
  26493. else
  26494. pkg_failed=untried
  26495. fi
  26496. if test -n "$GMIME_LIBS"; then
  26497. pkg_cv_GMIME_LIBS="$GMIME_LIBS"
  26498. elif test -n "$PKG_CONFIG"; then
  26499. if test -n "$PKG_CONFIG" && \
  26500. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gmime-\$ver\""; } >&5
  26501. ($PKG_CONFIG --exists --print-errors "gmime-$ver") 2>&5
  26502. ac_status=$?
  26503. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  26504. test $ac_status = 0; }; then
  26505. pkg_cv_GMIME_LIBS=`$PKG_CONFIG --libs "gmime-$ver" 2>/dev/null`
  26506. test "x$?" != "x0" && pkg_failed=yes
  26507. else
  26508. pkg_failed=yes
  26509. fi
  26510. else
  26511. pkg_failed=untried
  26512. fi
  26513. if test $pkg_failed = yes; then
  26514. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26515. $as_echo "no" >&6; }
  26516. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  26517. _pkg_short_errors_supported=yes
  26518. else
  26519. _pkg_short_errors_supported=no
  26520. fi
  26521. if test $_pkg_short_errors_supported = yes; then
  26522. GMIME_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gmime-$ver" 2>&1`
  26523. else
  26524. GMIME_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gmime-$ver" 2>&1`
  26525. fi
  26526. # Put the nasty error message in config.log where it belongs
  26527. echo "$GMIME_PKG_ERRORS" >&5
  26528. PBX_GMIME=0
  26529. elif test $pkg_failed = untried; then
  26530. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  26531. $as_echo "no" >&6; }
  26532. PBX_GMIME=0
  26533. else
  26534. GMIME_CFLAGS=$pkg_cv_GMIME_CFLAGS
  26535. GMIME_LIBS=$pkg_cv_GMIME_LIBS
  26536. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  26537. $as_echo "yes" >&6; }
  26538. PBX_GMIME=1
  26539. GMIME_INCLUDE="$GMIME_CFLAGS"
  26540. GMIME_LIB="$GMIME_LIBS"
  26541. $as_echo "#define HAVE_GMIME 1" >>confdefs.h
  26542. fi
  26543. fi
  26544. if test "$PBX_GMIME" = 1; then
  26545. break;
  26546. fi
  26547. done
  26548. if test "x${PBX_HOARD}" != "x1" -a "${USE_HOARD}" != "no"; then
  26549. pbxlibdir=""
  26550. # if --with-HOARD=DIR has been specified, use it.
  26551. if test "x${HOARD_DIR}" != "x"; then
  26552. if test -d ${HOARD_DIR}/lib; then
  26553. pbxlibdir="-L${HOARD_DIR}/lib"
  26554. else
  26555. pbxlibdir="-L${HOARD_DIR}"
  26556. fi
  26557. fi
  26558. pbxfuncname="malloc"
  26559. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26560. AST_HOARD_FOUND=yes
  26561. else
  26562. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26563. CFLAGS="${CFLAGS} "
  26564. as_ac_Lib=`$as_echo "ac_cv_lib_hoard_${pbxfuncname}" | $as_tr_sh`
  26565. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lhoard" >&5
  26566. $as_echo_n "checking for ${pbxfuncname} in -lhoard... " >&6; }
  26567. if eval \${$as_ac_Lib+:} false; then :
  26568. $as_echo_n "(cached) " >&6
  26569. else
  26570. ac_check_lib_save_LIBS=$LIBS
  26571. LIBS="-lhoard ${pbxlibdir} $LIBS"
  26572. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26573. /* end confdefs.h. */
  26574. /* Override any GCC internal prototype to avoid an error.
  26575. Use char because int might match the return type of a GCC
  26576. builtin and then its argument prototype would still apply. */
  26577. #ifdef __cplusplus
  26578. extern "C"
  26579. #endif
  26580. char ${pbxfuncname} ();
  26581. int
  26582. main ()
  26583. {
  26584. return ${pbxfuncname} ();
  26585. ;
  26586. return 0;
  26587. }
  26588. _ACEOF
  26589. if ac_fn_c_try_link "$LINENO"; then :
  26590. eval "$as_ac_Lib=yes"
  26591. else
  26592. eval "$as_ac_Lib=no"
  26593. fi
  26594. rm -f core conftest.err conftest.$ac_objext \
  26595. conftest$ac_exeext conftest.$ac_ext
  26596. LIBS=$ac_check_lib_save_LIBS
  26597. fi
  26598. eval ac_res=\$$as_ac_Lib
  26599. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26600. $as_echo "$ac_res" >&6; }
  26601. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26602. AST_HOARD_FOUND=yes
  26603. else
  26604. AST_HOARD_FOUND=no
  26605. fi
  26606. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26607. fi
  26608. # now check for the header.
  26609. if test "${AST_HOARD_FOUND}" = "yes"; then
  26610. HOARD_LIB="${pbxlibdir} -lhoard "
  26611. # if --with-HOARD=DIR has been specified, use it.
  26612. if test "x${HOARD_DIR}" != "x"; then
  26613. HOARD_INCLUDE="-I${HOARD_DIR}/include"
  26614. fi
  26615. HOARD_INCLUDE="${HOARD_INCLUDE} "
  26616. if test "x" = "x" ; then # no header, assume found
  26617. HOARD_HEADER_FOUND="1"
  26618. else # check for the header
  26619. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26620. CPPFLAGS="${CPPFLAGS} ${HOARD_INCLUDE}"
  26621. ac_fn_c_check_header_mongrel "$LINENO" "" "ac_cv_header_" "$ac_includes_default"
  26622. if test "x$ac_cv_header_" = xyes; then :
  26623. HOARD_HEADER_FOUND=1
  26624. else
  26625. HOARD_HEADER_FOUND=0
  26626. fi
  26627. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26628. fi
  26629. if test "x${HOARD_HEADER_FOUND}" = "x0" ; then
  26630. HOARD_LIB=""
  26631. HOARD_INCLUDE=""
  26632. else
  26633. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26634. HOARD_LIB=""
  26635. fi
  26636. PBX_HOARD=1
  26637. cat >>confdefs.h <<_ACEOF
  26638. #define HAVE_HOARD 1
  26639. _ACEOF
  26640. fi
  26641. fi
  26642. fi
  26643. if test "x${PBX_FREETDS}" != "x1" -a "${USE_FREETDS}" != "no"; then
  26644. pbxlibdir=""
  26645. # if --with-FREETDS=DIR has been specified, use it.
  26646. if test "x${FREETDS_DIR}" != "x"; then
  26647. if test -d ${FREETDS_DIR}/lib; then
  26648. pbxlibdir="-L${FREETDS_DIR}/lib"
  26649. else
  26650. pbxlibdir="-L${FREETDS_DIR}"
  26651. fi
  26652. fi
  26653. pbxfuncname="dbinit"
  26654. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26655. AST_FREETDS_FOUND=yes
  26656. else
  26657. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26658. CFLAGS="${CFLAGS} "
  26659. as_ac_Lib=`$as_echo "ac_cv_lib_sybdb_${pbxfuncname}" | $as_tr_sh`
  26660. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lsybdb" >&5
  26661. $as_echo_n "checking for ${pbxfuncname} in -lsybdb... " >&6; }
  26662. if eval \${$as_ac_Lib+:} false; then :
  26663. $as_echo_n "(cached) " >&6
  26664. else
  26665. ac_check_lib_save_LIBS=$LIBS
  26666. LIBS="-lsybdb ${pbxlibdir} $LIBS"
  26667. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26668. /* end confdefs.h. */
  26669. /* Override any GCC internal prototype to avoid an error.
  26670. Use char because int might match the return type of a GCC
  26671. builtin and then its argument prototype would still apply. */
  26672. #ifdef __cplusplus
  26673. extern "C"
  26674. #endif
  26675. char ${pbxfuncname} ();
  26676. int
  26677. main ()
  26678. {
  26679. return ${pbxfuncname} ();
  26680. ;
  26681. return 0;
  26682. }
  26683. _ACEOF
  26684. if ac_fn_c_try_link "$LINENO"; then :
  26685. eval "$as_ac_Lib=yes"
  26686. else
  26687. eval "$as_ac_Lib=no"
  26688. fi
  26689. rm -f core conftest.err conftest.$ac_objext \
  26690. conftest$ac_exeext conftest.$ac_ext
  26691. LIBS=$ac_check_lib_save_LIBS
  26692. fi
  26693. eval ac_res=\$$as_ac_Lib
  26694. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26695. $as_echo "$ac_res" >&6; }
  26696. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26697. AST_FREETDS_FOUND=yes
  26698. else
  26699. AST_FREETDS_FOUND=no
  26700. fi
  26701. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26702. fi
  26703. # now check for the header.
  26704. if test "${AST_FREETDS_FOUND}" = "yes"; then
  26705. FREETDS_LIB="${pbxlibdir} -lsybdb "
  26706. # if --with-FREETDS=DIR has been specified, use it.
  26707. if test "x${FREETDS_DIR}" != "x"; then
  26708. FREETDS_INCLUDE="-I${FREETDS_DIR}/include"
  26709. fi
  26710. FREETDS_INCLUDE="${FREETDS_INCLUDE} "
  26711. if test "xsybdb.h" = "x" ; then # no header, assume found
  26712. FREETDS_HEADER_FOUND="1"
  26713. else # check for the header
  26714. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26715. CPPFLAGS="${CPPFLAGS} ${FREETDS_INCLUDE}"
  26716. ac_fn_c_check_header_mongrel "$LINENO" "sybdb.h" "ac_cv_header_sybdb_h" "$ac_includes_default"
  26717. if test "x$ac_cv_header_sybdb_h" = xyes; then :
  26718. FREETDS_HEADER_FOUND=1
  26719. else
  26720. FREETDS_HEADER_FOUND=0
  26721. fi
  26722. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26723. fi
  26724. if test "x${FREETDS_HEADER_FOUND}" = "x0" ; then
  26725. FREETDS_LIB=""
  26726. FREETDS_INCLUDE=""
  26727. else
  26728. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26729. FREETDS_LIB=""
  26730. fi
  26731. PBX_FREETDS=1
  26732. cat >>confdefs.h <<_ACEOF
  26733. #define HAVE_FREETDS 1
  26734. _ACEOF
  26735. fi
  26736. fi
  26737. fi
  26738. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tone_zone_find_by_num in -ltonezone" >&5
  26739. $as_echo_n "checking for tone_zone_find_by_num in -ltonezone... " >&6; }
  26740. if ${ac_cv_lib_tonezone_tone_zone_find_by_num+:} false; then :
  26741. $as_echo_n "(cached) " >&6
  26742. else
  26743. ac_check_lib_save_LIBS=$LIBS
  26744. LIBS="-ltonezone $LIBS"
  26745. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26746. /* end confdefs.h. */
  26747. /* Override any GCC internal prototype to avoid an error.
  26748. Use char because int might match the return type of a GCC
  26749. builtin and then its argument prototype would still apply. */
  26750. #ifdef __cplusplus
  26751. extern "C"
  26752. #endif
  26753. char tone_zone_find_by_num ();
  26754. int
  26755. main ()
  26756. {
  26757. return tone_zone_find_by_num ();
  26758. ;
  26759. return 0;
  26760. }
  26761. _ACEOF
  26762. if ac_fn_c_try_link "$LINENO"; then :
  26763. ac_cv_lib_tonezone_tone_zone_find_by_num=yes
  26764. else
  26765. ac_cv_lib_tonezone_tone_zone_find_by_num=no
  26766. fi
  26767. rm -f core conftest.err conftest.$ac_objext \
  26768. conftest$ac_exeext conftest.$ac_ext
  26769. LIBS=$ac_check_lib_save_LIBS
  26770. fi
  26771. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tonezone_tone_zone_find_by_num" >&5
  26772. $as_echo "$ac_cv_lib_tonezone_tone_zone_find_by_num" >&6; }
  26773. if test "x$ac_cv_lib_tonezone_tone_zone_find_by_num" = xyes; then :
  26774. tonezone_does_not_need_lm=yes
  26775. else
  26776. tonezone_does_not_need_lm=no
  26777. fi
  26778. if test "${tonezone_does_not_need_lm}" = "no" ; then
  26779. tonezone_extra="-lm"
  26780. fi
  26781. if test "x${PBX_TONEZONE}" != "x1" -a "${USE_TONEZONE}" != "no"; then
  26782. pbxlibdir=""
  26783. # if --with-TONEZONE=DIR has been specified, use it.
  26784. if test "x${TONEZONE_DIR}" != "x"; then
  26785. if test -d ${TONEZONE_DIR}/lib; then
  26786. pbxlibdir="-L${TONEZONE_DIR}/lib"
  26787. else
  26788. pbxlibdir="-L${TONEZONE_DIR}"
  26789. fi
  26790. fi
  26791. pbxfuncname="tone_zone_find"
  26792. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26793. AST_TONEZONE_FOUND=yes
  26794. else
  26795. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26796. CFLAGS="${CFLAGS} "
  26797. as_ac_Lib=`$as_echo "ac_cv_lib_tonezone_${pbxfuncname}" | $as_tr_sh`
  26798. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -ltonezone" >&5
  26799. $as_echo_n "checking for ${pbxfuncname} in -ltonezone... " >&6; }
  26800. if eval \${$as_ac_Lib+:} false; then :
  26801. $as_echo_n "(cached) " >&6
  26802. else
  26803. ac_check_lib_save_LIBS=$LIBS
  26804. LIBS="-ltonezone ${pbxlibdir} ${tonezone_extra} ${DAHDI_INCLUDE} $LIBS"
  26805. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26806. /* end confdefs.h. */
  26807. /* Override any GCC internal prototype to avoid an error.
  26808. Use char because int might match the return type of a GCC
  26809. builtin and then its argument prototype would still apply. */
  26810. #ifdef __cplusplus
  26811. extern "C"
  26812. #endif
  26813. char ${pbxfuncname} ();
  26814. int
  26815. main ()
  26816. {
  26817. return ${pbxfuncname} ();
  26818. ;
  26819. return 0;
  26820. }
  26821. _ACEOF
  26822. if ac_fn_c_try_link "$LINENO"; then :
  26823. eval "$as_ac_Lib=yes"
  26824. else
  26825. eval "$as_ac_Lib=no"
  26826. fi
  26827. rm -f core conftest.err conftest.$ac_objext \
  26828. conftest$ac_exeext conftest.$ac_ext
  26829. LIBS=$ac_check_lib_save_LIBS
  26830. fi
  26831. eval ac_res=\$$as_ac_Lib
  26832. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26833. $as_echo "$ac_res" >&6; }
  26834. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26835. AST_TONEZONE_FOUND=yes
  26836. else
  26837. AST_TONEZONE_FOUND=no
  26838. fi
  26839. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26840. fi
  26841. # now check for the header.
  26842. if test "${AST_TONEZONE_FOUND}" = "yes"; then
  26843. TONEZONE_LIB="${pbxlibdir} -ltonezone ${tonezone_extra} ${DAHDI_INCLUDE}"
  26844. # if --with-TONEZONE=DIR has been specified, use it.
  26845. if test "x${TONEZONE_DIR}" != "x"; then
  26846. TONEZONE_INCLUDE="-I${TONEZONE_DIR}/include"
  26847. fi
  26848. TONEZONE_INCLUDE="${TONEZONE_INCLUDE} "
  26849. if test "xdahdi/tonezone.h" = "x" ; then # no header, assume found
  26850. TONEZONE_HEADER_FOUND="1"
  26851. else # check for the header
  26852. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26853. CPPFLAGS="${CPPFLAGS} ${TONEZONE_INCLUDE}"
  26854. ac_fn_c_check_header_mongrel "$LINENO" "dahdi/tonezone.h" "ac_cv_header_dahdi_tonezone_h" "$ac_includes_default"
  26855. if test "x$ac_cv_header_dahdi_tonezone_h" = xyes; then :
  26856. TONEZONE_HEADER_FOUND=1
  26857. else
  26858. TONEZONE_HEADER_FOUND=0
  26859. fi
  26860. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26861. fi
  26862. if test "x${TONEZONE_HEADER_FOUND}" = "x0" ; then
  26863. TONEZONE_LIB=""
  26864. TONEZONE_INCLUDE=""
  26865. else
  26866. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26867. TONEZONE_LIB=""
  26868. fi
  26869. PBX_TONEZONE=1
  26870. cat >>confdefs.h <<_ACEOF
  26871. #define HAVE_TONEZONE 1
  26872. _ACEOF
  26873. fi
  26874. fi
  26875. fi
  26876. if test "${OSARCH}" = "OpenBSD";
  26877. then
  26878. if test "x${PBX_VORBIS}" != "x1" -a "${USE_VORBIS}" != "no"; then
  26879. pbxlibdir=""
  26880. # if --with-VORBIS=DIR has been specified, use it.
  26881. if test "x${VORBIS_DIR}" != "x"; then
  26882. if test -d ${VORBIS_DIR}/lib; then
  26883. pbxlibdir="-L${VORBIS_DIR}/lib"
  26884. else
  26885. pbxlibdir="-L${VORBIS_DIR}"
  26886. fi
  26887. fi
  26888. pbxfuncname="vorbis_info_init"
  26889. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26890. AST_VORBIS_FOUND=yes
  26891. else
  26892. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26893. CFLAGS="${CFLAGS} "
  26894. as_ac_Lib=`$as_echo "ac_cv_lib_vorbis_${pbxfuncname}" | $as_tr_sh`
  26895. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lvorbis" >&5
  26896. $as_echo_n "checking for ${pbxfuncname} in -lvorbis... " >&6; }
  26897. if eval \${$as_ac_Lib+:} false; then :
  26898. $as_echo_n "(cached) " >&6
  26899. else
  26900. ac_check_lib_save_LIBS=$LIBS
  26901. LIBS="-lvorbis ${pbxlibdir} -lm -lvorbisenc -lvorbisfile -logg $LIBS"
  26902. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26903. /* end confdefs.h. */
  26904. /* Override any GCC internal prototype to avoid an error.
  26905. Use char because int might match the return type of a GCC
  26906. builtin and then its argument prototype would still apply. */
  26907. #ifdef __cplusplus
  26908. extern "C"
  26909. #endif
  26910. char ${pbxfuncname} ();
  26911. int
  26912. main ()
  26913. {
  26914. return ${pbxfuncname} ();
  26915. ;
  26916. return 0;
  26917. }
  26918. _ACEOF
  26919. if ac_fn_c_try_link "$LINENO"; then :
  26920. eval "$as_ac_Lib=yes"
  26921. else
  26922. eval "$as_ac_Lib=no"
  26923. fi
  26924. rm -f core conftest.err conftest.$ac_objext \
  26925. conftest$ac_exeext conftest.$ac_ext
  26926. LIBS=$ac_check_lib_save_LIBS
  26927. fi
  26928. eval ac_res=\$$as_ac_Lib
  26929. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  26930. $as_echo "$ac_res" >&6; }
  26931. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  26932. AST_VORBIS_FOUND=yes
  26933. else
  26934. AST_VORBIS_FOUND=no
  26935. fi
  26936. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  26937. fi
  26938. # now check for the header.
  26939. if test "${AST_VORBIS_FOUND}" = "yes"; then
  26940. VORBIS_LIB="${pbxlibdir} -lvorbis -lm -lvorbisenc -lvorbisfile -logg"
  26941. # if --with-VORBIS=DIR has been specified, use it.
  26942. if test "x${VORBIS_DIR}" != "x"; then
  26943. VORBIS_INCLUDE="-I${VORBIS_DIR}/include"
  26944. fi
  26945. VORBIS_INCLUDE="${VORBIS_INCLUDE} "
  26946. if test "xvorbis/codec.h" = "x" ; then # no header, assume found
  26947. VORBIS_HEADER_FOUND="1"
  26948. else # check for the header
  26949. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  26950. CPPFLAGS="${CPPFLAGS} ${VORBIS_INCLUDE}"
  26951. ac_fn_c_check_header_mongrel "$LINENO" "vorbis/codec.h" "ac_cv_header_vorbis_codec_h" "$ac_includes_default"
  26952. if test "x$ac_cv_header_vorbis_codec_h" = xyes; then :
  26953. VORBIS_HEADER_FOUND=1
  26954. else
  26955. VORBIS_HEADER_FOUND=0
  26956. fi
  26957. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  26958. fi
  26959. if test "x${VORBIS_HEADER_FOUND}" = "x0" ; then
  26960. VORBIS_LIB=""
  26961. VORBIS_INCLUDE=""
  26962. else
  26963. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  26964. VORBIS_LIB=""
  26965. fi
  26966. PBX_VORBIS=1
  26967. cat >>confdefs.h <<_ACEOF
  26968. #define HAVE_VORBIS 1
  26969. _ACEOF
  26970. fi
  26971. fi
  26972. fi
  26973. else
  26974. if test "x${PBX_VORBIS}" != "x1" -a "${USE_VORBIS}" != "no"; then
  26975. pbxlibdir=""
  26976. # if --with-VORBIS=DIR has been specified, use it.
  26977. if test "x${VORBIS_DIR}" != "x"; then
  26978. if test -d ${VORBIS_DIR}/lib; then
  26979. pbxlibdir="-L${VORBIS_DIR}/lib"
  26980. else
  26981. pbxlibdir="-L${VORBIS_DIR}"
  26982. fi
  26983. fi
  26984. pbxfuncname="vorbis_info_init"
  26985. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  26986. AST_VORBIS_FOUND=yes
  26987. else
  26988. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  26989. CFLAGS="${CFLAGS} "
  26990. as_ac_Lib=`$as_echo "ac_cv_lib_vorbis_${pbxfuncname}" | $as_tr_sh`
  26991. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lvorbis" >&5
  26992. $as_echo_n "checking for ${pbxfuncname} in -lvorbis... " >&6; }
  26993. if eval \${$as_ac_Lib+:} false; then :
  26994. $as_echo_n "(cached) " >&6
  26995. else
  26996. ac_check_lib_save_LIBS=$LIBS
  26997. LIBS="-lvorbis ${pbxlibdir} -lm -lvorbisenc -lvorbisfile $LIBS"
  26998. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  26999. /* end confdefs.h. */
  27000. /* Override any GCC internal prototype to avoid an error.
  27001. Use char because int might match the return type of a GCC
  27002. builtin and then its argument prototype would still apply. */
  27003. #ifdef __cplusplus
  27004. extern "C"
  27005. #endif
  27006. char ${pbxfuncname} ();
  27007. int
  27008. main ()
  27009. {
  27010. return ${pbxfuncname} ();
  27011. ;
  27012. return 0;
  27013. }
  27014. _ACEOF
  27015. if ac_fn_c_try_link "$LINENO"; then :
  27016. eval "$as_ac_Lib=yes"
  27017. else
  27018. eval "$as_ac_Lib=no"
  27019. fi
  27020. rm -f core conftest.err conftest.$ac_objext \
  27021. conftest$ac_exeext conftest.$ac_ext
  27022. LIBS=$ac_check_lib_save_LIBS
  27023. fi
  27024. eval ac_res=\$$as_ac_Lib
  27025. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27026. $as_echo "$ac_res" >&6; }
  27027. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27028. AST_VORBIS_FOUND=yes
  27029. else
  27030. AST_VORBIS_FOUND=no
  27031. fi
  27032. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27033. fi
  27034. # now check for the header.
  27035. if test "${AST_VORBIS_FOUND}" = "yes"; then
  27036. VORBIS_LIB="${pbxlibdir} -lvorbis -lm -lvorbisenc -lvorbisfile"
  27037. # if --with-VORBIS=DIR has been specified, use it.
  27038. if test "x${VORBIS_DIR}" != "x"; then
  27039. VORBIS_INCLUDE="-I${VORBIS_DIR}/include"
  27040. fi
  27041. VORBIS_INCLUDE="${VORBIS_INCLUDE} "
  27042. if test "xvorbis/codec.h" = "x" ; then # no header, assume found
  27043. VORBIS_HEADER_FOUND="1"
  27044. else # check for the header
  27045. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27046. CPPFLAGS="${CPPFLAGS} ${VORBIS_INCLUDE}"
  27047. ac_fn_c_check_header_mongrel "$LINENO" "vorbis/codec.h" "ac_cv_header_vorbis_codec_h" "$ac_includes_default"
  27048. if test "x$ac_cv_header_vorbis_codec_h" = xyes; then :
  27049. VORBIS_HEADER_FOUND=1
  27050. else
  27051. VORBIS_HEADER_FOUND=0
  27052. fi
  27053. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27054. fi
  27055. if test "x${VORBIS_HEADER_FOUND}" = "x0" ; then
  27056. VORBIS_LIB=""
  27057. VORBIS_INCLUDE=""
  27058. else
  27059. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27060. VORBIS_LIB=""
  27061. fi
  27062. PBX_VORBIS=1
  27063. cat >>confdefs.h <<_ACEOF
  27064. #define HAVE_VORBIS 1
  27065. _ACEOF
  27066. fi
  27067. fi
  27068. fi
  27069. fi
  27070. if test "x${PBX_VORBIS_OPEN_CALLBACKS}" != "x1" -a "${USE_VORBIS_OPEN_CALLBACKS}" != "no"; then
  27071. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OV_CALLBACKS_NOCLOSE declared in vorbis/vorbisfile.h" >&5
  27072. $as_echo_n "checking for OV_CALLBACKS_NOCLOSE declared in vorbis/vorbisfile.h... " >&6; }
  27073. saved_cppflags="${CPPFLAGS}"
  27074. if test "x${VORBIS_OPEN_CALLBACKS_DIR}" != "x"; then
  27075. VORBIS_OPEN_CALLBACKS_INCLUDE="-I${VORBIS_OPEN_CALLBACKS_DIR}/include"
  27076. fi
  27077. CPPFLAGS="${CPPFLAGS} ${VORBIS_OPEN_CALLBACKS_INCLUDE}"
  27078. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27079. /* end confdefs.h. */
  27080. #include <vorbis/vorbisfile.h>
  27081. int
  27082. main ()
  27083. {
  27084. #if !defined(OV_CALLBACKS_NOCLOSE)
  27085. (void) OV_CALLBACKS_NOCLOSE;
  27086. #endif
  27087. ;
  27088. return 0;
  27089. }
  27090. _ACEOF
  27091. if ac_fn_c_try_compile "$LINENO"; then :
  27092. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27093. $as_echo "yes" >&6; }
  27094. PBX_VORBIS_OPEN_CALLBACKS=1
  27095. $as_echo "#define HAVE_VORBIS_OPEN_CALLBACKS 1" >>confdefs.h
  27096. else
  27097. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27098. $as_echo "no" >&6; }
  27099. fi
  27100. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27101. CPPFLAGS="${saved_cppflags}"
  27102. fi
  27103. ac_ext=cpp
  27104. ac_cpp='$CXXCPP $CPPFLAGS'
  27105. ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  27106. ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  27107. ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
  27108. if test "${USE_VPB}" != "no"; then
  27109. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for vpb_open in -lvpb" >&5
  27110. $as_echo_n "checking for vpb_open in -lvpb... " >&6; }
  27111. saved_libs="${LIBS}"
  27112. saved_cppflags="${CPPFLAGS}"
  27113. if test "x${VPB_DIR}" != "x"; then
  27114. if test -d ${VPB_DIR}/lib; then
  27115. vpblibdir=${VPB_DIR}/lib
  27116. else
  27117. vpblibdir=${VPB_DIR}
  27118. fi
  27119. LIBS="${LIBS} -L${vpblibdir}"
  27120. CPPFLAGS="${CPPFLAGS} -I${VPB_DIR}/include"
  27121. fi
  27122. LIBS="${PTHREAD_LIBS} ${LIBS} -lvpb"
  27123. CPPFLAGS="${CPPFLAGS} ${PTHREAD_CFLAGS}"
  27124. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27125. /* end confdefs.h. */
  27126. #include <vpbapi.h>
  27127. int
  27128. main ()
  27129. {
  27130. int q = vpb_open(0,0);
  27131. ;
  27132. return 0;
  27133. }
  27134. _ACEOF
  27135. if ac_fn_cxx_try_link "$LINENO"; then :
  27136. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27137. $as_echo "yes" >&6; }
  27138. ac_cv_lib_vpb_vpb_open="yes"
  27139. else
  27140. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27141. $as_echo "no" >&6; }
  27142. ac_cv_lib_vpb_vpb_open="no"
  27143. fi
  27144. rm -f core conftest.err conftest.$ac_objext \
  27145. conftest$ac_exeext conftest.$ac_ext
  27146. LIBS="${saved_libs}"
  27147. CPPFLAGS="${saved_cppflags}"
  27148. if test "${ac_cv_lib_vpb_vpb_open}" = "yes"; then
  27149. VPB_LIB="-lvpb"
  27150. if test "${VPB_DIR}" != ""; then
  27151. VPB_LIB="-L${vpblibdir} ${VPB_LIB}"
  27152. VPB_INCLUDE="-I${VPB_DIR}/include"
  27153. fi
  27154. PBX_VPB=1
  27155. $as_echo "#define HAVE_VPB 1" >>confdefs.h
  27156. fi
  27157. fi
  27158. ac_ext=c
  27159. ac_cpp='$CPP $CPPFLAGS'
  27160. ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
  27161. ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
  27162. ac_compiler_gnu=$ac_cv_c_compiler_gnu
  27163. if test "x${PBX_ZLIB}" != "x1" -a "${USE_ZLIB}" != "no"; then
  27164. pbxlibdir=""
  27165. # if --with-ZLIB=DIR has been specified, use it.
  27166. if test "x${ZLIB_DIR}" != "x"; then
  27167. if test -d ${ZLIB_DIR}/lib; then
  27168. pbxlibdir="-L${ZLIB_DIR}/lib"
  27169. else
  27170. pbxlibdir="-L${ZLIB_DIR}"
  27171. fi
  27172. fi
  27173. pbxfuncname="compress"
  27174. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27175. AST_ZLIB_FOUND=yes
  27176. else
  27177. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27178. CFLAGS="${CFLAGS} "
  27179. as_ac_Lib=`$as_echo "ac_cv_lib_z_${pbxfuncname}" | $as_tr_sh`
  27180. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lz" >&5
  27181. $as_echo_n "checking for ${pbxfuncname} in -lz... " >&6; }
  27182. if eval \${$as_ac_Lib+:} false; then :
  27183. $as_echo_n "(cached) " >&6
  27184. else
  27185. ac_check_lib_save_LIBS=$LIBS
  27186. LIBS="-lz ${pbxlibdir} $LIBS"
  27187. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27188. /* end confdefs.h. */
  27189. /* Override any GCC internal prototype to avoid an error.
  27190. Use char because int might match the return type of a GCC
  27191. builtin and then its argument prototype would still apply. */
  27192. #ifdef __cplusplus
  27193. extern "C"
  27194. #endif
  27195. char ${pbxfuncname} ();
  27196. int
  27197. main ()
  27198. {
  27199. return ${pbxfuncname} ();
  27200. ;
  27201. return 0;
  27202. }
  27203. _ACEOF
  27204. if ac_fn_c_try_link "$LINENO"; then :
  27205. eval "$as_ac_Lib=yes"
  27206. else
  27207. eval "$as_ac_Lib=no"
  27208. fi
  27209. rm -f core conftest.err conftest.$ac_objext \
  27210. conftest$ac_exeext conftest.$ac_ext
  27211. LIBS=$ac_check_lib_save_LIBS
  27212. fi
  27213. eval ac_res=\$$as_ac_Lib
  27214. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27215. $as_echo "$ac_res" >&6; }
  27216. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27217. AST_ZLIB_FOUND=yes
  27218. else
  27219. AST_ZLIB_FOUND=no
  27220. fi
  27221. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27222. fi
  27223. # now check for the header.
  27224. if test "${AST_ZLIB_FOUND}" = "yes"; then
  27225. ZLIB_LIB="${pbxlibdir} -lz "
  27226. # if --with-ZLIB=DIR has been specified, use it.
  27227. if test "x${ZLIB_DIR}" != "x"; then
  27228. ZLIB_INCLUDE="-I${ZLIB_DIR}/include"
  27229. fi
  27230. ZLIB_INCLUDE="${ZLIB_INCLUDE} "
  27231. if test "xzlib.h" = "x" ; then # no header, assume found
  27232. ZLIB_HEADER_FOUND="1"
  27233. else # check for the header
  27234. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27235. CPPFLAGS="${CPPFLAGS} ${ZLIB_INCLUDE}"
  27236. ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
  27237. if test "x$ac_cv_header_zlib_h" = xyes; then :
  27238. ZLIB_HEADER_FOUND=1
  27239. else
  27240. ZLIB_HEADER_FOUND=0
  27241. fi
  27242. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27243. fi
  27244. if test "x${ZLIB_HEADER_FOUND}" = "x0" ; then
  27245. ZLIB_LIB=""
  27246. ZLIB_INCLUDE=""
  27247. else
  27248. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27249. ZLIB_LIB=""
  27250. fi
  27251. PBX_ZLIB=1
  27252. cat >>confdefs.h <<_ACEOF
  27253. #define HAVE_ZLIB 1
  27254. _ACEOF
  27255. fi
  27256. fi
  27257. fi
  27258. if test "x${PBX_UNIXODBC}" = "x1" -o "x${PBX_IODBC}" = "x1"; then
  27259. # Does ODBC support wide characters?
  27260. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ODBC has support for Unicode types" >&5
  27261. $as_echo_n "checking whether ODBC has support for Unicode types... " >&6; }
  27262. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27263. /* end confdefs.h. */
  27264. #include <sql.h>
  27265. #include <sqlext.h>
  27266. int
  27267. main ()
  27268. {
  27269. int foo = SQL_WCHAR
  27270. ;
  27271. return 0;
  27272. }
  27273. _ACEOF
  27274. if ac_fn_c_try_link "$LINENO"; then :
  27275. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27276. $as_echo "yes" >&6; }
  27277. $as_echo "#define HAVE_ODBC_WCHAR 1" >>confdefs.h
  27278. else
  27279. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27280. $as_echo "no" >&6; }
  27281. fi
  27282. rm -f core conftest.err conftest.$ac_objext \
  27283. conftest$ac_exeext conftest.$ac_ext
  27284. fi
  27285. ac_fn_c_check_header_mongrel "$LINENO" "linux/compiler.h" "ac_cv_header_linux_compiler_h" "$ac_includes_default"
  27286. if test "x$ac_cv_header_linux_compiler_h" = xyes; then :
  27287. cat >>confdefs.h <<_ACEOF
  27288. #define HAVE_LINUX_COMPILER_H 1
  27289. _ACEOF
  27290. fi
  27291. ac_fn_c_check_header_compile "$LINENO" "linux/ixjuser.h" "ac_cv_header_linux_ixjuser_h" "
  27292. #include <linux/version.h>
  27293. #ifdef HAVE_LINUX_COMPILER_H
  27294. #include <linux/compiler.h>
  27295. #endif
  27296. "
  27297. if test "x$ac_cv_header_linux_ixjuser_h" = xyes; then :
  27298. PBX_IXJUSER=1
  27299. else
  27300. PBX_IXJUSER=0
  27301. fi
  27302. # Used in res/res_pktccops
  27303. if test "x${PBX_MSG_NOSIGNAL}" != "x1"; then
  27304. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSG_NOSIGNAL in sys/socket.h" >&5
  27305. $as_echo_n "checking for MSG_NOSIGNAL in sys/socket.h... " >&6; }
  27306. saved_cppflags="${CPPFLAGS}"
  27307. if test "x${MSG_NOSIGNAL_DIR}" != "x"; then
  27308. MSG_NOSIGNAL_INCLUDE="-I${MSG_NOSIGNAL_DIR}/include"
  27309. fi
  27310. CPPFLAGS="${CPPFLAGS} ${MSG_NOSIGNAL_INCLUDE}"
  27311. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27312. /* end confdefs.h. */
  27313. #include <sys/socket.h>
  27314. int
  27315. main ()
  27316. {
  27317. #if defined(MSG_NOSIGNAL)
  27318. int foo = 0;
  27319. #else
  27320. int foo = bar;
  27321. #endif
  27322. 0
  27323. ;
  27324. return 0;
  27325. }
  27326. _ACEOF
  27327. if ac_fn_c_try_compile "$LINENO"; then :
  27328. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27329. $as_echo "yes" >&6; }
  27330. PBX_MSG_NOSIGNAL=1
  27331. $as_echo "#define HAVE_MSG_NOSIGNAL 1" >>confdefs.h
  27332. else
  27333. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27334. $as_echo "no" >&6; }
  27335. fi
  27336. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27337. CPPFLAGS="${saved_cppflags}"
  27338. fi
  27339. if test "x${PBX_SO_NOSIGPIPE}" != "x1"; then
  27340. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SO_NOSIGPIPE in sys/socket.h" >&5
  27341. $as_echo_n "checking for SO_NOSIGPIPE in sys/socket.h... " >&6; }
  27342. saved_cppflags="${CPPFLAGS}"
  27343. if test "x${SO_NOSIGPIPE_DIR}" != "x"; then
  27344. SO_NOSIGPIPE_INCLUDE="-I${SO_NOSIGPIPE_DIR}/include"
  27345. fi
  27346. CPPFLAGS="${CPPFLAGS} ${SO_NOSIGPIPE_INCLUDE}"
  27347. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27348. /* end confdefs.h. */
  27349. #include <sys/socket.h>
  27350. int
  27351. main ()
  27352. {
  27353. #if defined(SO_NOSIGPIPE)
  27354. int foo = 0;
  27355. #else
  27356. int foo = bar;
  27357. #endif
  27358. 0
  27359. ;
  27360. return 0;
  27361. }
  27362. _ACEOF
  27363. if ac_fn_c_try_compile "$LINENO"; then :
  27364. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27365. $as_echo "yes" >&6; }
  27366. PBX_SO_NOSIGPIPE=1
  27367. $as_echo "#define HAVE_SO_NOSIGPIPE 1" >>confdefs.h
  27368. else
  27369. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27370. $as_echo "no" >&6; }
  27371. fi
  27372. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  27373. CPPFLAGS="${saved_cppflags}"
  27374. fi
  27375. if test "x${PBX_SDL}" != "x1" -a "${USE_SDL}" != "no"; then
  27376. PBX_SDL=0
  27377. if test -n "$ac_tool_prefix"; then
  27378. # Extract the first word of "${ac_tool_prefix}sdl-config", so it can be a program name with args.
  27379. set dummy ${ac_tool_prefix}sdl-config; ac_word=$2
  27380. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  27381. $as_echo_n "checking for $ac_word... " >&6; }
  27382. if ${ac_cv_path_CONFIG_SDL+:} false; then :
  27383. $as_echo_n "(cached) " >&6
  27384. else
  27385. case $CONFIG_SDL in
  27386. [\\/]* | ?:[\\/]*)
  27387. ac_cv_path_CONFIG_SDL="$CONFIG_SDL" # Let the user override the test with a path.
  27388. ;;
  27389. *)
  27390. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  27391. as_dummy="${SDL_DIR}/bin:$PATH"
  27392. for as_dir in $as_dummy
  27393. do
  27394. IFS=$as_save_IFS
  27395. test -z "$as_dir" && as_dir=.
  27396. for ac_exec_ext in '' $ac_executable_extensions; do
  27397. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  27398. ac_cv_path_CONFIG_SDL="$as_dir/$ac_word$ac_exec_ext"
  27399. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  27400. break 2
  27401. fi
  27402. done
  27403. done
  27404. IFS=$as_save_IFS
  27405. ;;
  27406. esac
  27407. fi
  27408. CONFIG_SDL=$ac_cv_path_CONFIG_SDL
  27409. if test -n "$CONFIG_SDL"; then
  27410. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONFIG_SDL" >&5
  27411. $as_echo "$CONFIG_SDL" >&6; }
  27412. else
  27413. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27414. $as_echo "no" >&6; }
  27415. fi
  27416. fi
  27417. if test -z "$ac_cv_path_CONFIG_SDL"; then
  27418. ac_pt_CONFIG_SDL=$CONFIG_SDL
  27419. # Extract the first word of "sdl-config", so it can be a program name with args.
  27420. set dummy sdl-config; ac_word=$2
  27421. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
  27422. $as_echo_n "checking for $ac_word... " >&6; }
  27423. if ${ac_cv_path_ac_pt_CONFIG_SDL+:} false; then :
  27424. $as_echo_n "(cached) " >&6
  27425. else
  27426. case $ac_pt_CONFIG_SDL in
  27427. [\\/]* | ?:[\\/]*)
  27428. ac_cv_path_ac_pt_CONFIG_SDL="$ac_pt_CONFIG_SDL" # Let the user override the test with a path.
  27429. ;;
  27430. *)
  27431. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  27432. as_dummy="${SDL_DIR}/bin:$PATH"
  27433. for as_dir in $as_dummy
  27434. do
  27435. IFS=$as_save_IFS
  27436. test -z "$as_dir" && as_dir=.
  27437. for ac_exec_ext in '' $ac_executable_extensions; do
  27438. if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
  27439. ac_cv_path_ac_pt_CONFIG_SDL="$as_dir/$ac_word$ac_exec_ext"
  27440. $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
  27441. break 2
  27442. fi
  27443. done
  27444. done
  27445. IFS=$as_save_IFS
  27446. ;;
  27447. esac
  27448. fi
  27449. ac_pt_CONFIG_SDL=$ac_cv_path_ac_pt_CONFIG_SDL
  27450. if test -n "$ac_pt_CONFIG_SDL"; then
  27451. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_CONFIG_SDL" >&5
  27452. $as_echo "$ac_pt_CONFIG_SDL" >&6; }
  27453. else
  27454. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27455. $as_echo "no" >&6; }
  27456. fi
  27457. if test "x$ac_pt_CONFIG_SDL" = x; then
  27458. CONFIG_SDL="No"
  27459. else
  27460. case $cross_compiling:$ac_tool_warned in
  27461. yes:)
  27462. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
  27463. $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
  27464. ac_tool_warned=yes ;;
  27465. esac
  27466. CONFIG_SDL=$ac_pt_CONFIG_SDL
  27467. fi
  27468. else
  27469. CONFIG_SDL="$ac_cv_path_CONFIG_SDL"
  27470. fi
  27471. if test ! "x${CONFIG_SDL}" = xNo; then
  27472. if test x"" = x ; then A=--cflags ; else A="" ; fi
  27473. SDL_INCLUDE=$(${CONFIG_SDL} $A)
  27474. SDL_INCLUDE=$(echo ${SDL_INCLUDE} | $SED -e "s|-I|-I${SDL_DIR}|g")
  27475. if test x"" = x ; then A=--libs ; else A="" ; fi
  27476. SDL_LIB=$(${CONFIG_SDL} $A)
  27477. SDL_LIB=$(echo ${SDL_LIB} | $SED -e "s|-L|-L${SDL_DIR}|g")
  27478. if test x"" != x ; then
  27479. saved_cppflags="${CPPFLAGS}"
  27480. CPPFLAGS="${CPPFLAGS} ${SDL_INCLUDE}"
  27481. saved_libs="${LIBS}"
  27482. LIBS=${SDL_LIB}
  27483. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27484. /* end confdefs.h. */
  27485. int
  27486. main ()
  27487. {
  27488. ;
  27489. ;
  27490. return 0;
  27491. }
  27492. _ACEOF
  27493. if ac_fn_c_try_link "$LINENO"; then :
  27494. PBX_SDL=1
  27495. $as_echo "#define HAVE_SDL 1" >>confdefs.h
  27496. fi
  27497. rm -f core conftest.err conftest.$ac_objext \
  27498. conftest$ac_exeext conftest.$ac_ext
  27499. CPPFLAGS="${saved_cppflags}"
  27500. LIBS="${saved_libs}"
  27501. else
  27502. PBX_SDL=1
  27503. $as_echo "#define HAVE_SDL 1" >>confdefs.h
  27504. fi
  27505. fi
  27506. fi
  27507. if test "x${PBX_SDL_IMAGE}" != "x1" -a "${USE_SDL_IMAGE}" != "no"; then
  27508. pbxlibdir=""
  27509. # if --with-SDL_IMAGE=DIR has been specified, use it.
  27510. if test "x${SDL_IMAGE_DIR}" != "x"; then
  27511. if test -d ${SDL_IMAGE_DIR}/lib; then
  27512. pbxlibdir="-L${SDL_IMAGE_DIR}/lib"
  27513. else
  27514. pbxlibdir="-L${SDL_IMAGE_DIR}"
  27515. fi
  27516. fi
  27517. pbxfuncname="IMG_Load"
  27518. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27519. AST_SDL_IMAGE_FOUND=yes
  27520. else
  27521. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27522. CFLAGS="${CFLAGS} ${SDL_INCLUDE}"
  27523. as_ac_Lib=`$as_echo "ac_cv_lib_SDL_image_${pbxfuncname}" | $as_tr_sh`
  27524. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lSDL_image" >&5
  27525. $as_echo_n "checking for ${pbxfuncname} in -lSDL_image... " >&6; }
  27526. if eval \${$as_ac_Lib+:} false; then :
  27527. $as_echo_n "(cached) " >&6
  27528. else
  27529. ac_check_lib_save_LIBS=$LIBS
  27530. LIBS="-lSDL_image ${pbxlibdir} ${SDL_LIB} $LIBS"
  27531. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27532. /* end confdefs.h. */
  27533. /* Override any GCC internal prototype to avoid an error.
  27534. Use char because int might match the return type of a GCC
  27535. builtin and then its argument prototype would still apply. */
  27536. #ifdef __cplusplus
  27537. extern "C"
  27538. #endif
  27539. char ${pbxfuncname} ();
  27540. int
  27541. main ()
  27542. {
  27543. return ${pbxfuncname} ();
  27544. ;
  27545. return 0;
  27546. }
  27547. _ACEOF
  27548. if ac_fn_c_try_link "$LINENO"; then :
  27549. eval "$as_ac_Lib=yes"
  27550. else
  27551. eval "$as_ac_Lib=no"
  27552. fi
  27553. rm -f core conftest.err conftest.$ac_objext \
  27554. conftest$ac_exeext conftest.$ac_ext
  27555. LIBS=$ac_check_lib_save_LIBS
  27556. fi
  27557. eval ac_res=\$$as_ac_Lib
  27558. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27559. $as_echo "$ac_res" >&6; }
  27560. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27561. AST_SDL_IMAGE_FOUND=yes
  27562. else
  27563. AST_SDL_IMAGE_FOUND=no
  27564. fi
  27565. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27566. fi
  27567. # now check for the header.
  27568. if test "${AST_SDL_IMAGE_FOUND}" = "yes"; then
  27569. SDL_IMAGE_LIB="${pbxlibdir} -lSDL_image ${SDL_LIB}"
  27570. # if --with-SDL_IMAGE=DIR has been specified, use it.
  27571. if test "x${SDL_IMAGE_DIR}" != "x"; then
  27572. SDL_IMAGE_INCLUDE="-I${SDL_IMAGE_DIR}/include"
  27573. fi
  27574. SDL_IMAGE_INCLUDE="${SDL_IMAGE_INCLUDE} ${SDL_INCLUDE}"
  27575. if test "xSDL_image.h" = "x" ; then # no header, assume found
  27576. SDL_IMAGE_HEADER_FOUND="1"
  27577. else # check for the header
  27578. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27579. CPPFLAGS="${CPPFLAGS} ${SDL_IMAGE_INCLUDE}"
  27580. ac_fn_c_check_header_mongrel "$LINENO" "SDL_image.h" "ac_cv_header_SDL_image_h" "$ac_includes_default"
  27581. if test "x$ac_cv_header_SDL_image_h" = xyes; then :
  27582. SDL_IMAGE_HEADER_FOUND=1
  27583. else
  27584. SDL_IMAGE_HEADER_FOUND=0
  27585. fi
  27586. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27587. fi
  27588. if test "x${SDL_IMAGE_HEADER_FOUND}" = "x0" ; then
  27589. SDL_IMAGE_LIB=""
  27590. SDL_IMAGE_INCLUDE=""
  27591. else
  27592. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27593. SDL_IMAGE_LIB=""
  27594. fi
  27595. PBX_SDL_IMAGE=1
  27596. cat >>confdefs.h <<_ACEOF
  27597. #define HAVE_SDL_IMAGE 1
  27598. _ACEOF
  27599. fi
  27600. fi
  27601. fi
  27602. if test "x${PBX_FFMPEG}" != "x1" -a "${USE_FFMPEG}" != "no"; then
  27603. pbxlibdir=""
  27604. # if --with-FFMPEG=DIR has been specified, use it.
  27605. if test "x${FFMPEG_DIR}" != "x"; then
  27606. if test -d ${FFMPEG_DIR}/lib; then
  27607. pbxlibdir="-L${FFMPEG_DIR}/lib"
  27608. else
  27609. pbxlibdir="-L${FFMPEG_DIR}"
  27610. fi
  27611. fi
  27612. pbxfuncname="sws_getContext"
  27613. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27614. AST_FFMPEG_FOUND=yes
  27615. else
  27616. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27617. CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
  27618. as_ac_Lib=`$as_echo "ac_cv_lib_avcodec_${pbxfuncname}" | $as_tr_sh`
  27619. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lavcodec" >&5
  27620. $as_echo_n "checking for ${pbxfuncname} in -lavcodec... " >&6; }
  27621. if eval \${$as_ac_Lib+:} false; then :
  27622. $as_echo_n "(cached) " >&6
  27623. else
  27624. ac_check_lib_save_LIBS=$LIBS
  27625. LIBS="-lavcodec ${pbxlibdir} ${PTHREAD_LIBS} -lz -lm $LIBS"
  27626. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27627. /* end confdefs.h. */
  27628. /* Override any GCC internal prototype to avoid an error.
  27629. Use char because int might match the return type of a GCC
  27630. builtin and then its argument prototype would still apply. */
  27631. #ifdef __cplusplus
  27632. extern "C"
  27633. #endif
  27634. char ${pbxfuncname} ();
  27635. int
  27636. main ()
  27637. {
  27638. return ${pbxfuncname} ();
  27639. ;
  27640. return 0;
  27641. }
  27642. _ACEOF
  27643. if ac_fn_c_try_link "$LINENO"; then :
  27644. eval "$as_ac_Lib=yes"
  27645. else
  27646. eval "$as_ac_Lib=no"
  27647. fi
  27648. rm -f core conftest.err conftest.$ac_objext \
  27649. conftest$ac_exeext conftest.$ac_ext
  27650. LIBS=$ac_check_lib_save_LIBS
  27651. fi
  27652. eval ac_res=\$$as_ac_Lib
  27653. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27654. $as_echo "$ac_res" >&6; }
  27655. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27656. AST_FFMPEG_FOUND=yes
  27657. else
  27658. AST_FFMPEG_FOUND=no
  27659. fi
  27660. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27661. fi
  27662. # now check for the header.
  27663. if test "${AST_FFMPEG_FOUND}" = "yes"; then
  27664. FFMPEG_LIB="${pbxlibdir} -lavcodec ${PTHREAD_LIBS} -lz -lm"
  27665. # if --with-FFMPEG=DIR has been specified, use it.
  27666. if test "x${FFMPEG_DIR}" != "x"; then
  27667. FFMPEG_INCLUDE="-I${FFMPEG_DIR}/include"
  27668. fi
  27669. FFMPEG_INCLUDE="${FFMPEG_INCLUDE} ${PTHREAD_CFLAGS}"
  27670. if test "xffmpeg/avcodec.h" = "x" ; then # no header, assume found
  27671. FFMPEG_HEADER_FOUND="1"
  27672. else # check for the header
  27673. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27674. CPPFLAGS="${CPPFLAGS} ${FFMPEG_INCLUDE}"
  27675. ac_fn_c_check_header_mongrel "$LINENO" "ffmpeg/avcodec.h" "ac_cv_header_ffmpeg_avcodec_h" "$ac_includes_default"
  27676. if test "x$ac_cv_header_ffmpeg_avcodec_h" = xyes; then :
  27677. FFMPEG_HEADER_FOUND=1
  27678. else
  27679. FFMPEG_HEADER_FOUND=0
  27680. fi
  27681. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27682. fi
  27683. if test "x${FFMPEG_HEADER_FOUND}" = "x0" ; then
  27684. FFMPEG_LIB=""
  27685. FFMPEG_INCLUDE=""
  27686. else
  27687. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27688. FFMPEG_LIB=""
  27689. fi
  27690. PBX_FFMPEG=1
  27691. cat >>confdefs.h <<_ACEOF
  27692. #define HAVE_FFMPEG 1
  27693. _ACEOF
  27694. fi
  27695. fi
  27696. fi
  27697. # possible places for video4linux version 1
  27698. ac_fn_c_check_header_mongrel "$LINENO" "linux/videodev.h" "ac_cv_header_linux_videodev_h" "$ac_includes_default"
  27699. if test "x$ac_cv_header_linux_videodev_h" = xyes; then :
  27700. cat >>confdefs.h <<_ACEOF
  27701. #define HAVE_VIDEODEV_H 1
  27702. _ACEOF
  27703. fi
  27704. # possible places for X11
  27705. if test "x${PBX_X11}" != "x1" -a "${USE_X11}" != "no"; then
  27706. pbxlibdir=""
  27707. # if --with-X11=DIR has been specified, use it.
  27708. if test "x${X11_DIR}" != "x"; then
  27709. if test -d ${X11_DIR}/lib; then
  27710. pbxlibdir="-L${X11_DIR}/lib"
  27711. else
  27712. pbxlibdir="-L${X11_DIR}"
  27713. fi
  27714. fi
  27715. pbxfuncname="XOpenDisplay"
  27716. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27717. AST_X11_FOUND=yes
  27718. else
  27719. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27720. CFLAGS="${CFLAGS} "
  27721. as_ac_Lib=`$as_echo "ac_cv_lib_X11_${pbxfuncname}" | $as_tr_sh`
  27722. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lX11" >&5
  27723. $as_echo_n "checking for ${pbxfuncname} in -lX11... " >&6; }
  27724. if eval \${$as_ac_Lib+:} false; then :
  27725. $as_echo_n "(cached) " >&6
  27726. else
  27727. ac_check_lib_save_LIBS=$LIBS
  27728. LIBS="-lX11 ${pbxlibdir} $LIBS"
  27729. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27730. /* end confdefs.h. */
  27731. /* Override any GCC internal prototype to avoid an error.
  27732. Use char because int might match the return type of a GCC
  27733. builtin and then its argument prototype would still apply. */
  27734. #ifdef __cplusplus
  27735. extern "C"
  27736. #endif
  27737. char ${pbxfuncname} ();
  27738. int
  27739. main ()
  27740. {
  27741. return ${pbxfuncname} ();
  27742. ;
  27743. return 0;
  27744. }
  27745. _ACEOF
  27746. if ac_fn_c_try_link "$LINENO"; then :
  27747. eval "$as_ac_Lib=yes"
  27748. else
  27749. eval "$as_ac_Lib=no"
  27750. fi
  27751. rm -f core conftest.err conftest.$ac_objext \
  27752. conftest$ac_exeext conftest.$ac_ext
  27753. LIBS=$ac_check_lib_save_LIBS
  27754. fi
  27755. eval ac_res=\$$as_ac_Lib
  27756. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27757. $as_echo "$ac_res" >&6; }
  27758. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27759. AST_X11_FOUND=yes
  27760. else
  27761. AST_X11_FOUND=no
  27762. fi
  27763. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27764. fi
  27765. # now check for the header.
  27766. if test "${AST_X11_FOUND}" = "yes"; then
  27767. X11_LIB="${pbxlibdir} -lX11 "
  27768. # if --with-X11=DIR has been specified, use it.
  27769. if test "x${X11_DIR}" != "x"; then
  27770. X11_INCLUDE="-I${X11_DIR}/include"
  27771. fi
  27772. X11_INCLUDE="${X11_INCLUDE} "
  27773. if test "xX11/Xlib.h" = "x" ; then # no header, assume found
  27774. X11_HEADER_FOUND="1"
  27775. else # check for the header
  27776. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27777. CPPFLAGS="${CPPFLAGS} ${X11_INCLUDE}"
  27778. ac_fn_c_check_header_mongrel "$LINENO" "X11/Xlib.h" "ac_cv_header_X11_Xlib_h" "$ac_includes_default"
  27779. if test "x$ac_cv_header_X11_Xlib_h" = xyes; then :
  27780. X11_HEADER_FOUND=1
  27781. else
  27782. X11_HEADER_FOUND=0
  27783. fi
  27784. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27785. fi
  27786. if test "x${X11_HEADER_FOUND}" = "x0" ; then
  27787. X11_LIB=""
  27788. X11_INCLUDE=""
  27789. else
  27790. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27791. X11_LIB=""
  27792. fi
  27793. PBX_X11=1
  27794. cat >>confdefs.h <<_ACEOF
  27795. #define HAVE_X11 1
  27796. _ACEOF
  27797. cat >>confdefs.h <<_ACEOF
  27798. #define HAVE_X11_VERSION standard_path
  27799. _ACEOF
  27800. fi
  27801. fi
  27802. fi
  27803. if test "x${PBX_X11}" != "x1" -a "${USE_X11}" != "no"; then
  27804. pbxlibdir=""
  27805. # if --with-X11=DIR has been specified, use it.
  27806. if test "x${X11_DIR}" != "x"; then
  27807. if test -d ${X11_DIR}/lib; then
  27808. pbxlibdir="-L${X11_DIR}/lib"
  27809. else
  27810. pbxlibdir="-L${X11_DIR}"
  27811. fi
  27812. fi
  27813. pbxfuncname="XOpenDisplay"
  27814. if test "x${pbxfuncname}" = "x" ; then # empty lib, assume only headers
  27815. AST_X11_FOUND=yes
  27816. else
  27817. ast_ext_lib_check_save_CFLAGS="${CFLAGS}"
  27818. CFLAGS="${CFLAGS} -I/usr/X11R6/include"
  27819. as_ac_Lib=`$as_echo "ac_cv_lib_X11_${pbxfuncname}" | $as_tr_sh`
  27820. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${pbxfuncname} in -lX11" >&5
  27821. $as_echo_n "checking for ${pbxfuncname} in -lX11... " >&6; }
  27822. if eval \${$as_ac_Lib+:} false; then :
  27823. $as_echo_n "(cached) " >&6
  27824. else
  27825. ac_check_lib_save_LIBS=$LIBS
  27826. LIBS="-lX11 ${pbxlibdir} $LIBS"
  27827. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  27828. /* end confdefs.h. */
  27829. /* Override any GCC internal prototype to avoid an error.
  27830. Use char because int might match the return type of a GCC
  27831. builtin and then its argument prototype would still apply. */
  27832. #ifdef __cplusplus
  27833. extern "C"
  27834. #endif
  27835. char ${pbxfuncname} ();
  27836. int
  27837. main ()
  27838. {
  27839. return ${pbxfuncname} ();
  27840. ;
  27841. return 0;
  27842. }
  27843. _ACEOF
  27844. if ac_fn_c_try_link "$LINENO"; then :
  27845. eval "$as_ac_Lib=yes"
  27846. else
  27847. eval "$as_ac_Lib=no"
  27848. fi
  27849. rm -f core conftest.err conftest.$ac_objext \
  27850. conftest$ac_exeext conftest.$ac_ext
  27851. LIBS=$ac_check_lib_save_LIBS
  27852. fi
  27853. eval ac_res=\$$as_ac_Lib
  27854. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
  27855. $as_echo "$ac_res" >&6; }
  27856. if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
  27857. AST_X11_FOUND=yes
  27858. else
  27859. AST_X11_FOUND=no
  27860. fi
  27861. CFLAGS="${ast_ext_lib_check_save_CFLAGS}"
  27862. fi
  27863. # now check for the header.
  27864. if test "${AST_X11_FOUND}" = "yes"; then
  27865. X11_LIB="${pbxlibdir} -lX11 "
  27866. # if --with-X11=DIR has been specified, use it.
  27867. if test "x${X11_DIR}" != "x"; then
  27868. X11_INCLUDE="-I${X11_DIR}/include"
  27869. fi
  27870. X11_INCLUDE="${X11_INCLUDE} -I/usr/X11R6/include"
  27871. if test "xX11/Xlib.h" = "x" ; then # no header, assume found
  27872. X11_HEADER_FOUND="1"
  27873. else # check for the header
  27874. ast_ext_lib_check_saved_CPPFLAGS="${CPPFLAGS}"
  27875. CPPFLAGS="${CPPFLAGS} ${X11_INCLUDE}"
  27876. ac_fn_c_check_header_mongrel "$LINENO" "X11/Xlib.h" "ac_cv_header_X11_Xlib_h" "$ac_includes_default"
  27877. if test "x$ac_cv_header_X11_Xlib_h" = xyes; then :
  27878. X11_HEADER_FOUND=1
  27879. else
  27880. X11_HEADER_FOUND=0
  27881. fi
  27882. CPPFLAGS="${ast_ext_lib_check_saved_CPPFLAGS}"
  27883. fi
  27884. if test "x${X11_HEADER_FOUND}" = "x0" ; then
  27885. X11_LIB=""
  27886. X11_INCLUDE=""
  27887. else
  27888. if test "x${pbxfuncname}" = "x" ; then # only checking headers -> no library
  27889. X11_LIB=""
  27890. fi
  27891. PBX_X11=1
  27892. cat >>confdefs.h <<_ACEOF
  27893. #define HAVE_X11 1
  27894. _ACEOF
  27895. cat >>confdefs.h <<_ACEOF
  27896. #define HAVE_X11_VERSION X11R6
  27897. _ACEOF
  27898. fi
  27899. fi
  27900. fi
  27901. PBX_LAUNCHD=0
  27902. if test "${cross_compiling}" = "no";
  27903. then
  27904. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /sbin/launchd" >&5
  27905. $as_echo_n "checking for /sbin/launchd... " >&6; }
  27906. if ${ac_cv_file__sbin_launchd+:} false; then :
  27907. $as_echo_n "(cached) " >&6
  27908. else
  27909. test "$cross_compiling" = yes &&
  27910. as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
  27911. if test -r "/sbin/launchd"; then
  27912. ac_cv_file__sbin_launchd=yes
  27913. else
  27914. ac_cv_file__sbin_launchd=no
  27915. fi
  27916. fi
  27917. { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__sbin_launchd" >&5
  27918. $as_echo "$ac_cv_file__sbin_launchd" >&6; }
  27919. if test "x$ac_cv_file__sbin_launchd" = xyes; then :
  27920. PBX_LAUNCHD=1
  27921. $as_echo "#define HAVE_SBIN_LAUNCHD 1" >>confdefs.h
  27922. fi
  27923. fi
  27924. if test "x${PBX_GTK2}" != "x1" -a "${USE_GTK2}" != "no"; then
  27925. pkg_failed=no
  27926. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK2" >&5
  27927. $as_echo_n "checking for GTK2... " >&6; }
  27928. if test -n "$GTK2_CFLAGS"; then
  27929. pkg_cv_GTK2_CFLAGS="$GTK2_CFLAGS"
  27930. elif test -n "$PKG_CONFIG"; then
  27931. if test -n "$PKG_CONFIG" && \
  27932. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-2.0\""; } >&5
  27933. ($PKG_CONFIG --exists --print-errors "gtk+-2.0") 2>&5
  27934. ac_status=$?
  27935. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  27936. test $ac_status = 0; }; then
  27937. pkg_cv_GTK2_CFLAGS=`$PKG_CONFIG --cflags "gtk+-2.0" 2>/dev/null`
  27938. test "x$?" != "x0" && pkg_failed=yes
  27939. else
  27940. pkg_failed=yes
  27941. fi
  27942. else
  27943. pkg_failed=untried
  27944. fi
  27945. if test -n "$GTK2_LIBS"; then
  27946. pkg_cv_GTK2_LIBS="$GTK2_LIBS"
  27947. elif test -n "$PKG_CONFIG"; then
  27948. if test -n "$PKG_CONFIG" && \
  27949. { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-2.0\""; } >&5
  27950. ($PKG_CONFIG --exists --print-errors "gtk+-2.0") 2>&5
  27951. ac_status=$?
  27952. $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
  27953. test $ac_status = 0; }; then
  27954. pkg_cv_GTK2_LIBS=`$PKG_CONFIG --libs "gtk+-2.0" 2>/dev/null`
  27955. test "x$?" != "x0" && pkg_failed=yes
  27956. else
  27957. pkg_failed=yes
  27958. fi
  27959. else
  27960. pkg_failed=untried
  27961. fi
  27962. if test $pkg_failed = yes; then
  27963. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27964. $as_echo "no" >&6; }
  27965. if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
  27966. _pkg_short_errors_supported=yes
  27967. else
  27968. _pkg_short_errors_supported=no
  27969. fi
  27970. if test $_pkg_short_errors_supported = yes; then
  27971. GTK2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gtk+-2.0" 2>&1`
  27972. else
  27973. GTK2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gtk+-2.0" 2>&1`
  27974. fi
  27975. # Put the nasty error message in config.log where it belongs
  27976. echo "$GTK2_PKG_ERRORS" >&5
  27977. PBX_GTK2=0
  27978. elif test $pkg_failed = untried; then
  27979. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  27980. $as_echo "no" >&6; }
  27981. PBX_GTK2=0
  27982. else
  27983. GTK2_CFLAGS=$pkg_cv_GTK2_CFLAGS
  27984. GTK2_LIBS=$pkg_cv_GTK2_LIBS
  27985. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  27986. $as_echo "yes" >&6; }
  27987. PBX_GTK2=1
  27988. GTK2_INCLUDE="$GTK2_CFLAGS"
  27989. GTK2_LIB="$GTK2_LIBS"
  27990. $as_echo "#define HAVE_GTK2 1" >>confdefs.h
  27991. fi
  27992. fi
  27993. # build a GENERIC_ODBC result based on the presence of either UnixODBC (preferred)
  27994. # or iODBC
  27995. PBX_GENERIC_ODBC=0
  27996. if test "${PBX_UNIXODBC}" = 1; then
  27997. PBX_GENERIC_ODBC=1
  27998. GENERIC_ODBC_LIB="${UNIXODBC_LIB}"
  27999. GENERIC_ODBC_INCLUDE="${UNIXODBC_INCLUDE}"
  28000. elif test "${PBX_IODBC}" = 1; then
  28001. PBX_GENERIC_ODBC=1
  28002. GENERIC_ODBC_LIB="${IODBC_LIB}"
  28003. GENERIC_ODBC_INCLUDE="${IODBC_INCLUDE}"
  28004. fi
  28005. PBX_SYSLOG=0
  28006. if test "${ac_cv_header_syslog_h}" = "yes"; then
  28007. # syslog facilities
  28008. if test "x${PBX_SYSLOG_FACILITY_LOG_AUTH}" != "x1"; then
  28009. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_AUTH in syslog.h" >&5
  28010. $as_echo_n "checking for LOG_AUTH in syslog.h... " >&6; }
  28011. saved_cppflags="${CPPFLAGS}"
  28012. if test "x${SYSLOG_FACILITY_LOG_AUTH_DIR}" != "x"; then
  28013. SYSLOG_FACILITY_LOG_AUTH_INCLUDE="-I${SYSLOG_FACILITY_LOG_AUTH_DIR}/include"
  28014. fi
  28015. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_AUTH_INCLUDE}"
  28016. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28017. /* end confdefs.h. */
  28018. #include <syslog.h>
  28019. int
  28020. main ()
  28021. {
  28022. #if defined(LOG_AUTH)
  28023. int foo = 0;
  28024. #else
  28025. int foo = bar;
  28026. #endif
  28027. 0
  28028. ;
  28029. return 0;
  28030. }
  28031. _ACEOF
  28032. if ac_fn_c_try_compile "$LINENO"; then :
  28033. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28034. $as_echo "yes" >&6; }
  28035. PBX_SYSLOG_FACILITY_LOG_AUTH=1
  28036. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_AUTH 1" >>confdefs.h
  28037. else
  28038. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28039. $as_echo "no" >&6; }
  28040. fi
  28041. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28042. CPPFLAGS="${saved_cppflags}"
  28043. fi
  28044. if test "x${PBX_SYSLOG_FACILITY_LOG_AUTHPRIV}" != "x1"; then
  28045. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_AUTHPRIV in syslog.h" >&5
  28046. $as_echo_n "checking for LOG_AUTHPRIV in syslog.h... " >&6; }
  28047. saved_cppflags="${CPPFLAGS}"
  28048. if test "x${SYSLOG_FACILITY_LOG_AUTHPRIV_DIR}" != "x"; then
  28049. SYSLOG_FACILITY_LOG_AUTHPRIV_INCLUDE="-I${SYSLOG_FACILITY_LOG_AUTHPRIV_DIR}/include"
  28050. fi
  28051. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_AUTHPRIV_INCLUDE}"
  28052. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28053. /* end confdefs.h. */
  28054. #include <syslog.h>
  28055. int
  28056. main ()
  28057. {
  28058. #if defined(LOG_AUTHPRIV)
  28059. int foo = 0;
  28060. #else
  28061. int foo = bar;
  28062. #endif
  28063. 0
  28064. ;
  28065. return 0;
  28066. }
  28067. _ACEOF
  28068. if ac_fn_c_try_compile "$LINENO"; then :
  28069. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28070. $as_echo "yes" >&6; }
  28071. PBX_SYSLOG_FACILITY_LOG_AUTHPRIV=1
  28072. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_AUTHPRIV 1" >>confdefs.h
  28073. else
  28074. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28075. $as_echo "no" >&6; }
  28076. fi
  28077. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28078. CPPFLAGS="${saved_cppflags}"
  28079. fi
  28080. if test "x${PBX_SYSLOG_FACILITY_LOG_CRON}" != "x1"; then
  28081. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_CRON in syslog.h" >&5
  28082. $as_echo_n "checking for LOG_CRON in syslog.h... " >&6; }
  28083. saved_cppflags="${CPPFLAGS}"
  28084. if test "x${SYSLOG_FACILITY_LOG_CRON_DIR}" != "x"; then
  28085. SYSLOG_FACILITY_LOG_CRON_INCLUDE="-I${SYSLOG_FACILITY_LOG_CRON_DIR}/include"
  28086. fi
  28087. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_CRON_INCLUDE}"
  28088. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28089. /* end confdefs.h. */
  28090. #include <syslog.h>
  28091. int
  28092. main ()
  28093. {
  28094. #if defined(LOG_CRON)
  28095. int foo = 0;
  28096. #else
  28097. int foo = bar;
  28098. #endif
  28099. 0
  28100. ;
  28101. return 0;
  28102. }
  28103. _ACEOF
  28104. if ac_fn_c_try_compile "$LINENO"; then :
  28105. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28106. $as_echo "yes" >&6; }
  28107. PBX_SYSLOG_FACILITY_LOG_CRON=1
  28108. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_CRON 1" >>confdefs.h
  28109. else
  28110. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28111. $as_echo "no" >&6; }
  28112. fi
  28113. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28114. CPPFLAGS="${saved_cppflags}"
  28115. fi
  28116. if test "x${PBX_SYSLOG_FACILITY_LOG_DAEMON}" != "x1"; then
  28117. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_DAEMON in syslog.h" >&5
  28118. $as_echo_n "checking for LOG_DAEMON in syslog.h... " >&6; }
  28119. saved_cppflags="${CPPFLAGS}"
  28120. if test "x${SYSLOG_FACILITY_LOG_DAEMON_DIR}" != "x"; then
  28121. SYSLOG_FACILITY_LOG_DAEMON_INCLUDE="-I${SYSLOG_FACILITY_LOG_DAEMON_DIR}/include"
  28122. fi
  28123. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_DAEMON_INCLUDE}"
  28124. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28125. /* end confdefs.h. */
  28126. #include <syslog.h>
  28127. int
  28128. main ()
  28129. {
  28130. #if defined(LOG_DAEMON)
  28131. int foo = 0;
  28132. #else
  28133. int foo = bar;
  28134. #endif
  28135. 0
  28136. ;
  28137. return 0;
  28138. }
  28139. _ACEOF
  28140. if ac_fn_c_try_compile "$LINENO"; then :
  28141. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28142. $as_echo "yes" >&6; }
  28143. PBX_SYSLOG_FACILITY_LOG_DAEMON=1
  28144. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_DAEMON 1" >>confdefs.h
  28145. else
  28146. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28147. $as_echo "no" >&6; }
  28148. fi
  28149. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28150. CPPFLAGS="${saved_cppflags}"
  28151. fi
  28152. if test "x${PBX_SYSLOG_FACILITY_LOG_FTP}" != "x1"; then
  28153. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_FTP in syslog.h" >&5
  28154. $as_echo_n "checking for LOG_FTP in syslog.h... " >&6; }
  28155. saved_cppflags="${CPPFLAGS}"
  28156. if test "x${SYSLOG_FACILITY_LOG_FTP_DIR}" != "x"; then
  28157. SYSLOG_FACILITY_LOG_FTP_INCLUDE="-I${SYSLOG_FACILITY_LOG_FTP_DIR}/include"
  28158. fi
  28159. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_FTP_INCLUDE}"
  28160. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28161. /* end confdefs.h. */
  28162. #include <syslog.h>
  28163. int
  28164. main ()
  28165. {
  28166. #if defined(LOG_FTP)
  28167. int foo = 0;
  28168. #else
  28169. int foo = bar;
  28170. #endif
  28171. 0
  28172. ;
  28173. return 0;
  28174. }
  28175. _ACEOF
  28176. if ac_fn_c_try_compile "$LINENO"; then :
  28177. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28178. $as_echo "yes" >&6; }
  28179. PBX_SYSLOG_FACILITY_LOG_FTP=1
  28180. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_FTP 1" >>confdefs.h
  28181. else
  28182. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28183. $as_echo "no" >&6; }
  28184. fi
  28185. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28186. CPPFLAGS="${saved_cppflags}"
  28187. fi
  28188. if test "x${PBX_SYSLOG_FACILITY_LOG_KERN}" != "x1"; then
  28189. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_KERN in syslog.h" >&5
  28190. $as_echo_n "checking for LOG_KERN in syslog.h... " >&6; }
  28191. saved_cppflags="${CPPFLAGS}"
  28192. if test "x${SYSLOG_FACILITY_LOG_KERN_DIR}" != "x"; then
  28193. SYSLOG_FACILITY_LOG_KERN_INCLUDE="-I${SYSLOG_FACILITY_LOG_KERN_DIR}/include"
  28194. fi
  28195. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_KERN_INCLUDE}"
  28196. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28197. /* end confdefs.h. */
  28198. #include <syslog.h>
  28199. int
  28200. main ()
  28201. {
  28202. #if defined(LOG_KERN)
  28203. int foo = 0;
  28204. #else
  28205. int foo = bar;
  28206. #endif
  28207. 0
  28208. ;
  28209. return 0;
  28210. }
  28211. _ACEOF
  28212. if ac_fn_c_try_compile "$LINENO"; then :
  28213. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28214. $as_echo "yes" >&6; }
  28215. PBX_SYSLOG_FACILITY_LOG_KERN=1
  28216. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_KERN 1" >>confdefs.h
  28217. else
  28218. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28219. $as_echo "no" >&6; }
  28220. fi
  28221. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28222. CPPFLAGS="${saved_cppflags}"
  28223. fi
  28224. if test "x${PBX_SYSLOG_FACILITY_LOG_LPR}" != "x1"; then
  28225. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_LPR in syslog.h" >&5
  28226. $as_echo_n "checking for LOG_LPR in syslog.h... " >&6; }
  28227. saved_cppflags="${CPPFLAGS}"
  28228. if test "x${SYSLOG_FACILITY_LOG_LPR_DIR}" != "x"; then
  28229. SYSLOG_FACILITY_LOG_LPR_INCLUDE="-I${SYSLOG_FACILITY_LOG_LPR_DIR}/include"
  28230. fi
  28231. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_LPR_INCLUDE}"
  28232. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28233. /* end confdefs.h. */
  28234. #include <syslog.h>
  28235. int
  28236. main ()
  28237. {
  28238. #if defined(LOG_LPR)
  28239. int foo = 0;
  28240. #else
  28241. int foo = bar;
  28242. #endif
  28243. 0
  28244. ;
  28245. return 0;
  28246. }
  28247. _ACEOF
  28248. if ac_fn_c_try_compile "$LINENO"; then :
  28249. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28250. $as_echo "yes" >&6; }
  28251. PBX_SYSLOG_FACILITY_LOG_LPR=1
  28252. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_LPR 1" >>confdefs.h
  28253. else
  28254. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28255. $as_echo "no" >&6; }
  28256. fi
  28257. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28258. CPPFLAGS="${saved_cppflags}"
  28259. fi
  28260. if test "x${PBX_SYSLOG_FACILITY_LOG_MAIL}" != "x1"; then
  28261. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_MAIL in syslog.h" >&5
  28262. $as_echo_n "checking for LOG_MAIL in syslog.h... " >&6; }
  28263. saved_cppflags="${CPPFLAGS}"
  28264. if test "x${SYSLOG_FACILITY_LOG_MAIL_DIR}" != "x"; then
  28265. SYSLOG_FACILITY_LOG_MAIL_INCLUDE="-I${SYSLOG_FACILITY_LOG_MAIL_DIR}/include"
  28266. fi
  28267. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_MAIL_INCLUDE}"
  28268. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28269. /* end confdefs.h. */
  28270. #include <syslog.h>
  28271. int
  28272. main ()
  28273. {
  28274. #if defined(LOG_MAIL)
  28275. int foo = 0;
  28276. #else
  28277. int foo = bar;
  28278. #endif
  28279. 0
  28280. ;
  28281. return 0;
  28282. }
  28283. _ACEOF
  28284. if ac_fn_c_try_compile "$LINENO"; then :
  28285. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28286. $as_echo "yes" >&6; }
  28287. PBX_SYSLOG_FACILITY_LOG_MAIL=1
  28288. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_MAIL 1" >>confdefs.h
  28289. else
  28290. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28291. $as_echo "no" >&6; }
  28292. fi
  28293. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28294. CPPFLAGS="${saved_cppflags}"
  28295. fi
  28296. if test "x${PBX_SYSLOG_FACILITY_LOG_NEWS}" != "x1"; then
  28297. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_NEWS in syslog.h" >&5
  28298. $as_echo_n "checking for LOG_NEWS in syslog.h... " >&6; }
  28299. saved_cppflags="${CPPFLAGS}"
  28300. if test "x${SYSLOG_FACILITY_LOG_NEWS_DIR}" != "x"; then
  28301. SYSLOG_FACILITY_LOG_NEWS_INCLUDE="-I${SYSLOG_FACILITY_LOG_NEWS_DIR}/include"
  28302. fi
  28303. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_NEWS_INCLUDE}"
  28304. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28305. /* end confdefs.h. */
  28306. #include <syslog.h>
  28307. int
  28308. main ()
  28309. {
  28310. #if defined(LOG_NEWS)
  28311. int foo = 0;
  28312. #else
  28313. int foo = bar;
  28314. #endif
  28315. 0
  28316. ;
  28317. return 0;
  28318. }
  28319. _ACEOF
  28320. if ac_fn_c_try_compile "$LINENO"; then :
  28321. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28322. $as_echo "yes" >&6; }
  28323. PBX_SYSLOG_FACILITY_LOG_NEWS=1
  28324. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_NEWS 1" >>confdefs.h
  28325. else
  28326. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28327. $as_echo "no" >&6; }
  28328. fi
  28329. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28330. CPPFLAGS="${saved_cppflags}"
  28331. fi
  28332. if test "x${PBX_SYSLOG_FACILITY_LOG_SYSLOG}" != "x1"; then
  28333. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_SYSLOG in syslog.h" >&5
  28334. $as_echo_n "checking for LOG_SYSLOG in syslog.h... " >&6; }
  28335. saved_cppflags="${CPPFLAGS}"
  28336. if test "x${SYSLOG_FACILITY_LOG_SYSLOG_DIR}" != "x"; then
  28337. SYSLOG_FACILITY_LOG_SYSLOG_INCLUDE="-I${SYSLOG_FACILITY_LOG_SYSLOG_DIR}/include"
  28338. fi
  28339. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_SYSLOG_INCLUDE}"
  28340. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28341. /* end confdefs.h. */
  28342. #include <syslog.h>
  28343. int
  28344. main ()
  28345. {
  28346. #if defined(LOG_SYSLOG)
  28347. int foo = 0;
  28348. #else
  28349. int foo = bar;
  28350. #endif
  28351. 0
  28352. ;
  28353. return 0;
  28354. }
  28355. _ACEOF
  28356. if ac_fn_c_try_compile "$LINENO"; then :
  28357. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28358. $as_echo "yes" >&6; }
  28359. PBX_SYSLOG_FACILITY_LOG_SYSLOG=1
  28360. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_SYSLOG 1" >>confdefs.h
  28361. else
  28362. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28363. $as_echo "no" >&6; }
  28364. fi
  28365. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28366. CPPFLAGS="${saved_cppflags}"
  28367. fi
  28368. if test "x${PBX_SYSLOG_FACILITY_LOG_UUCP}" != "x1"; then
  28369. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LOG_UUCP in syslog.h" >&5
  28370. $as_echo_n "checking for LOG_UUCP in syslog.h... " >&6; }
  28371. saved_cppflags="${CPPFLAGS}"
  28372. if test "x${SYSLOG_FACILITY_LOG_UUCP_DIR}" != "x"; then
  28373. SYSLOG_FACILITY_LOG_UUCP_INCLUDE="-I${SYSLOG_FACILITY_LOG_UUCP_DIR}/include"
  28374. fi
  28375. CPPFLAGS="${CPPFLAGS} ${SYSLOG_FACILITY_LOG_UUCP_INCLUDE}"
  28376. cat confdefs.h - <<_ACEOF >conftest.$ac_ext
  28377. /* end confdefs.h. */
  28378. #include <syslog.h>
  28379. int
  28380. main ()
  28381. {
  28382. #if defined(LOG_UUCP)
  28383. int foo = 0;
  28384. #else
  28385. int foo = bar;
  28386. #endif
  28387. 0
  28388. ;
  28389. return 0;
  28390. }
  28391. _ACEOF
  28392. if ac_fn_c_try_compile "$LINENO"; then :
  28393. { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  28394. $as_echo "yes" >&6; }
  28395. PBX_SYSLOG_FACILITY_LOG_UUCP=1
  28396. $as_echo "#define HAVE_SYSLOG_FACILITY_LOG_UUCP 1" >>confdefs.h
  28397. else
  28398. { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
  28399. $as_echo "no" >&6; }
  28400. fi
  28401. rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  28402. CPPFLAGS="${saved_cppflags}"
  28403. fi
  28404. PBX_SYSLOG=1
  28405. fi
  28406. if test -f makeopts; then
  28407. ${ac_cv_path_EGREP} 'CURSES|GTK2|OSARCH|NEWT' makeopts > makeopts.acbak
  28408. else
  28409. touch makeopts.acbak
  28410. fi
  28411. ac_config_files="$ac_config_files build_tools/menuselect-deps makeopts"
  28412. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mandatory modules: ${ac_mandatory_list}" >&5
  28413. $as_echo_n "checking for mandatory modules: ${ac_mandatory_list}... " >&6; }
  28414. err=0;
  28415. for i in ${ac_mandatory_list}; do
  28416. eval "a=\${PBX_$i}"
  28417. if test "x${a}" = "x1" ; then continue; fi
  28418. if test ${err} = "0" ; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: fail" >&5
  28419. $as_echo "fail" >&6; } ; fi
  28420. { $as_echo "$as_me:${as_lineno-$LINENO}: result: " >&5
  28421. $as_echo "" >&6; }
  28422. eval "a=\${${i}_OPTION}"
  28423. { $as_echo "$as_me:${as_lineno-$LINENO}: ***" >&5
  28424. $as_echo "$as_me: ***" >&6;}
  28425. { $as_echo "$as_me:${as_lineno-$LINENO}: *** The $i installation appears to be missing or broken." >&5
  28426. $as_echo "$as_me: *** The $i installation appears to be missing or broken." >&6;}
  28427. { $as_echo "$as_me:${as_lineno-$LINENO}: *** Either correct the installation, or run configure" >&5
  28428. $as_echo "$as_me: *** Either correct the installation, or run configure" >&6;}
  28429. { $as_echo "$as_me:${as_lineno-$LINENO}: *** including --without-${a}." >&5
  28430. $as_echo "$as_me: *** including --without-${a}." >&6;}
  28431. err=1
  28432. done
  28433. if test $err = 1 ; then exit 1; fi
  28434. { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
  28435. $as_echo "ok" >&6; }
  28436. if test -f build_tools/menuselect-deps; then
  28437. # extract old values of all PBX_ variables from menuselect-deps
  28438. # and preserve them so that menuselect can determine whether
  28439. # any previously-met dependencies are no longer met and warn
  28440. # the user appropriately
  28441. while IFS="=:" read var val old_val; do
  28442. eval "PBX_${var}=\${PBX_${var}}:${val}"
  28443. done < build_tools/menuselect-deps
  28444. fi
  28445. cat >confcache <<\_ACEOF
  28446. # This file is a shell script that caches the results of configure
  28447. # tests run on this system so they can be shared between configure
  28448. # scripts and configure runs, see configure's option --config-cache.
  28449. # It is not useful on other systems. If it contains results you don't
  28450. # want to keep, you may remove or edit it.
  28451. #
  28452. # config.status only pays attention to the cache file if you give it
  28453. # the --recheck option to rerun configure.
  28454. #
  28455. # `ac_cv_env_foo' variables (set or unset) will be overridden when
  28456. # loading this file, other *unset* `ac_cv_foo' will be assigned the
  28457. # following values.
  28458. _ACEOF
  28459. # The following way of writing the cache mishandles newlines in values,
  28460. # but we know of no workaround that is simple, portable, and efficient.
  28461. # So, we kill variables containing newlines.
  28462. # Ultrix sh set writes to stderr and can't be redirected directly,
  28463. # and sets the high bit in the cache file unless we assign to the vars.
  28464. (
  28465. for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
  28466. eval ac_val=\$$ac_var
  28467. case $ac_val in #(
  28468. *${as_nl}*)
  28469. case $ac_var in #(
  28470. *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
  28471. $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
  28472. esac
  28473. case $ac_var in #(
  28474. _ | IFS | as_nl) ;; #(
  28475. BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
  28476. *) { eval $ac_var=; unset $ac_var;} ;;
  28477. esac ;;
  28478. esac
  28479. done
  28480. (set) 2>&1 |
  28481. case $as_nl`(ac_space=' '; set) 2>&1` in #(
  28482. *${as_nl}ac_space=\ *)
  28483. # `set' does not quote correctly, so add quotes: double-quote
  28484. # substitution turns \\\\ into \\, and sed turns \\ into \.
  28485. sed -n \
  28486. "s/'/'\\\\''/g;
  28487. s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
  28488. ;; #(
  28489. *)
  28490. # `set' quotes correctly as required by POSIX, so do not add quotes.
  28491. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
  28492. ;;
  28493. esac |
  28494. sort
  28495. ) |
  28496. sed '
  28497. /^ac_cv_env_/b end
  28498. t clear
  28499. :clear
  28500. s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
  28501. t end
  28502. s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
  28503. :end' >>confcache
  28504. if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
  28505. if test -w "$cache_file"; then
  28506. if test "x$cache_file" != "x/dev/null"; then
  28507. { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
  28508. $as_echo "$as_me: updating cache $cache_file" >&6;}
  28509. if test ! -f "$cache_file" || test -h "$cache_file"; then
  28510. cat confcache >"$cache_file"
  28511. else
  28512. case $cache_file in #(
  28513. */* | ?:*)
  28514. mv -f confcache "$cache_file"$$ &&
  28515. mv -f "$cache_file"$$ "$cache_file" ;; #(
  28516. *)
  28517. mv -f confcache "$cache_file" ;;
  28518. esac
  28519. fi
  28520. fi
  28521. else
  28522. { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
  28523. $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
  28524. fi
  28525. fi
  28526. rm -f confcache
  28527. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  28528. # Let make expand exec_prefix.
  28529. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  28530. DEFS=-DHAVE_CONFIG_H
  28531. ac_libobjs=
  28532. ac_ltlibobjs=
  28533. U=
  28534. for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
  28535. # 1. Remove the extension, and $U if already installed.
  28536. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
  28537. ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
  28538. # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
  28539. # will be set to the directory where LIBOBJS objects are built.
  28540. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
  28541. as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
  28542. done
  28543. LIBOBJS=$ac_libobjs
  28544. LTLIBOBJS=$ac_ltlibobjs
  28545. : "${CONFIG_STATUS=./config.status}"
  28546. ac_write_fail=0
  28547. ac_clean_files_save=$ac_clean_files
  28548. ac_clean_files="$ac_clean_files $CONFIG_STATUS"
  28549. { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
  28550. $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
  28551. as_write_fail=0
  28552. cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
  28553. #! $SHELL
  28554. # Generated by $as_me.
  28555. # Run this file to recreate the current configuration.
  28556. # Compiler output produced by configure, useful for debugging
  28557. # configure, is in config.log if it exists.
  28558. debug=false
  28559. ac_cs_recheck=false
  28560. ac_cs_silent=false
  28561. SHELL=\${CONFIG_SHELL-$SHELL}
  28562. export SHELL
  28563. _ASEOF
  28564. cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
  28565. ## -------------------- ##
  28566. ## M4sh Initialization. ##
  28567. ## -------------------- ##
  28568. # Be more Bourne compatible
  28569. DUALCASE=1; export DUALCASE # for MKS sh
  28570. if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
  28571. emulate sh
  28572. NULLCMD=:
  28573. # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  28574. # is contrary to our usage. Disable this feature.
  28575. alias -g '${1+"$@"}'='"$@"'
  28576. setopt NO_GLOB_SUBST
  28577. else
  28578. case `(set -o) 2>/dev/null` in #(
  28579. *posix*) :
  28580. set -o posix ;; #(
  28581. *) :
  28582. ;;
  28583. esac
  28584. fi
  28585. as_nl='
  28586. '
  28587. export as_nl
  28588. # Printing a long string crashes Solaris 7 /usr/bin/printf.
  28589. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
  28590. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
  28591. as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
  28592. # Prefer a ksh shell builtin over an external printf program on Solaris,
  28593. # but without wasting forks for bash or zsh.
  28594. if test -z "$BASH_VERSION$ZSH_VERSION" \
  28595. && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
  28596. as_echo='print -r --'
  28597. as_echo_n='print -rn --'
  28598. elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  28599. as_echo='printf %s\n'
  28600. as_echo_n='printf %s'
  28601. else
  28602. if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
  28603. as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
  28604. as_echo_n='/usr/ucb/echo -n'
  28605. else
  28606. as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
  28607. as_echo_n_body='eval
  28608. arg=$1;
  28609. case $arg in #(
  28610. *"$as_nl"*)
  28611. expr "X$arg" : "X\\(.*\\)$as_nl";
  28612. arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
  28613. esac;
  28614. expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
  28615. '
  28616. export as_echo_n_body
  28617. as_echo_n='sh -c $as_echo_n_body as_echo'
  28618. fi
  28619. export as_echo_body
  28620. as_echo='sh -c $as_echo_body as_echo'
  28621. fi
  28622. # The user is always right.
  28623. if test "${PATH_SEPARATOR+set}" != set; then
  28624. PATH_SEPARATOR=:
  28625. (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
  28626. (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
  28627. PATH_SEPARATOR=';'
  28628. }
  28629. fi
  28630. # IFS
  28631. # We need space, tab and new line, in precisely that order. Quoting is
  28632. # there to prevent editors from complaining about space-tab.
  28633. # (If _AS_PATH_WALK were called with IFS unset, it would disable word
  28634. # splitting by setting IFS to empty value.)
  28635. IFS=" "" $as_nl"
  28636. # Find who we are. Look in the path if we contain no directory separator.
  28637. as_myself=
  28638. case $0 in #((
  28639. *[\\/]* ) as_myself=$0 ;;
  28640. *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  28641. for as_dir in $PATH
  28642. do
  28643. IFS=$as_save_IFS
  28644. test -z "$as_dir" && as_dir=.
  28645. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
  28646. done
  28647. IFS=$as_save_IFS
  28648. ;;
  28649. esac
  28650. # We did not find ourselves, most probably we were run as `sh COMMAND'
  28651. # in which case we are not to be found in the path.
  28652. if test "x$as_myself" = x; then
  28653. as_myself=$0
  28654. fi
  28655. if test ! -f "$as_myself"; then
  28656. $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
  28657. exit 1
  28658. fi
  28659. # Unset variables that we do not need and which cause bugs (e.g. in
  28660. # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
  28661. # suppresses any "Segmentation fault" message there. '((' could
  28662. # trigger a bug in pdksh 5.2.14.
  28663. for as_var in BASH_ENV ENV MAIL MAILPATH
  28664. do eval test x\${$as_var+set} = xset \
  28665. && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
  28666. done
  28667. PS1='$ '
  28668. PS2='> '
  28669. PS4='+ '
  28670. # NLS nuisances.
  28671. LC_ALL=C
  28672. export LC_ALL
  28673. LANGUAGE=C
  28674. export LANGUAGE
  28675. # CDPATH.
  28676. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
  28677. # as_fn_error STATUS ERROR [LINENO LOG_FD]
  28678. # ----------------------------------------
  28679. # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
  28680. # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
  28681. # script with STATUS, using 1 if that was 0.
  28682. as_fn_error ()
  28683. {
  28684. as_status=$1; test $as_status -eq 0 && as_status=1
  28685. if test "$4"; then
  28686. as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
  28687. $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
  28688. fi
  28689. $as_echo "$as_me: error: $2" >&2
  28690. as_fn_exit $as_status
  28691. } # as_fn_error
  28692. # as_fn_set_status STATUS
  28693. # -----------------------
  28694. # Set $? to STATUS, without forking.
  28695. as_fn_set_status ()
  28696. {
  28697. return $1
  28698. } # as_fn_set_status
  28699. # as_fn_exit STATUS
  28700. # -----------------
  28701. # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
  28702. as_fn_exit ()
  28703. {
  28704. set +e
  28705. as_fn_set_status $1
  28706. exit $1
  28707. } # as_fn_exit
  28708. # as_fn_unset VAR
  28709. # ---------------
  28710. # Portably unset VAR.
  28711. as_fn_unset ()
  28712. {
  28713. { eval $1=; unset $1;}
  28714. }
  28715. as_unset=as_fn_unset
  28716. # as_fn_append VAR VALUE
  28717. # ----------------------
  28718. # Append the text in VALUE to the end of the definition contained in VAR. Take
  28719. # advantage of any shell optimizations that allow amortized linear growth over
  28720. # repeated appends, instead of the typical quadratic growth present in naive
  28721. # implementations.
  28722. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
  28723. eval 'as_fn_append ()
  28724. {
  28725. eval $1+=\$2
  28726. }'
  28727. else
  28728. as_fn_append ()
  28729. {
  28730. eval $1=\$$1\$2
  28731. }
  28732. fi # as_fn_append
  28733. # as_fn_arith ARG...
  28734. # ------------------
  28735. # Perform arithmetic evaluation on the ARGs, and store the result in the
  28736. # global $as_val. Take advantage of shells that can avoid forks. The arguments
  28737. # must be portable across $(()) and expr.
  28738. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
  28739. eval 'as_fn_arith ()
  28740. {
  28741. as_val=$(( $* ))
  28742. }'
  28743. else
  28744. as_fn_arith ()
  28745. {
  28746. as_val=`expr "$@" || test $? -eq 1`
  28747. }
  28748. fi # as_fn_arith
  28749. if expr a : '\(a\)' >/dev/null 2>&1 &&
  28750. test "X`expr 00001 : '.*\(...\)'`" = X001; then
  28751. as_expr=expr
  28752. else
  28753. as_expr=false
  28754. fi
  28755. if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
  28756. as_basename=basename
  28757. else
  28758. as_basename=false
  28759. fi
  28760. if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
  28761. as_dirname=dirname
  28762. else
  28763. as_dirname=false
  28764. fi
  28765. as_me=`$as_basename -- "$0" ||
  28766. $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
  28767. X"$0" : 'X\(//\)$' \| \
  28768. X"$0" : 'X\(/\)' \| . 2>/dev/null ||
  28769. $as_echo X/"$0" |
  28770. sed '/^.*\/\([^/][^/]*\)\/*$/{
  28771. s//\1/
  28772. q
  28773. }
  28774. /^X\/\(\/\/\)$/{
  28775. s//\1/
  28776. q
  28777. }
  28778. /^X\/\(\/\).*/{
  28779. s//\1/
  28780. q
  28781. }
  28782. s/.*/./; q'`
  28783. # Avoid depending upon Character Ranges.
  28784. as_cr_letters='abcdefghijklmnopqrstuvwxyz'
  28785. as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
  28786. as_cr_Letters=$as_cr_letters$as_cr_LETTERS
  28787. as_cr_digits='0123456789'
  28788. as_cr_alnum=$as_cr_Letters$as_cr_digits
  28789. ECHO_C= ECHO_N= ECHO_T=
  28790. case `echo -n x` in #(((((
  28791. -n*)
  28792. case `echo 'xy\c'` in
  28793. *c*) ECHO_T=' ';; # ECHO_T is single tab character.
  28794. xy) ECHO_C='\c';;
  28795. *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
  28796. ECHO_T=' ';;
  28797. esac;;
  28798. *)
  28799. ECHO_N='-n';;
  28800. esac
  28801. rm -f conf$$ conf$$.exe conf$$.file
  28802. if test -d conf$$.dir; then
  28803. rm -f conf$$.dir/conf$$.file
  28804. else
  28805. rm -f conf$$.dir
  28806. mkdir conf$$.dir 2>/dev/null
  28807. fi
  28808. if (echo >conf$$.file) 2>/dev/null; then
  28809. if ln -s conf$$.file conf$$ 2>/dev/null; then
  28810. as_ln_s='ln -s'
  28811. # ... but there are two gotchas:
  28812. # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
  28813. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
  28814. # In both cases, we have to default to `cp -pR'.
  28815. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
  28816. as_ln_s='cp -pR'
  28817. elif ln conf$$.file conf$$ 2>/dev/null; then
  28818. as_ln_s=ln
  28819. else
  28820. as_ln_s='cp -pR'
  28821. fi
  28822. else
  28823. as_ln_s='cp -pR'
  28824. fi
  28825. rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
  28826. rmdir conf$$.dir 2>/dev/null
  28827. # as_fn_mkdir_p
  28828. # -------------
  28829. # Create "$as_dir" as a directory, including parents if necessary.
  28830. as_fn_mkdir_p ()
  28831. {
  28832. case $as_dir in #(
  28833. -*) as_dir=./$as_dir;;
  28834. esac
  28835. test -d "$as_dir" || eval $as_mkdir_p || {
  28836. as_dirs=
  28837. while :; do
  28838. case $as_dir in #(
  28839. *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
  28840. *) as_qdir=$as_dir;;
  28841. esac
  28842. as_dirs="'$as_qdir' $as_dirs"
  28843. as_dir=`$as_dirname -- "$as_dir" ||
  28844. $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  28845. X"$as_dir" : 'X\(//\)[^/]' \| \
  28846. X"$as_dir" : 'X\(//\)$' \| \
  28847. X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
  28848. $as_echo X"$as_dir" |
  28849. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  28850. s//\1/
  28851. q
  28852. }
  28853. /^X\(\/\/\)[^/].*/{
  28854. s//\1/
  28855. q
  28856. }
  28857. /^X\(\/\/\)$/{
  28858. s//\1/
  28859. q
  28860. }
  28861. /^X\(\/\).*/{
  28862. s//\1/
  28863. q
  28864. }
  28865. s/.*/./; q'`
  28866. test -d "$as_dir" && break
  28867. done
  28868. test -z "$as_dirs" || eval "mkdir $as_dirs"
  28869. } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
  28870. } # as_fn_mkdir_p
  28871. if mkdir -p . 2>/dev/null; then
  28872. as_mkdir_p='mkdir -p "$as_dir"'
  28873. else
  28874. test -d ./-p && rmdir ./-p
  28875. as_mkdir_p=false
  28876. fi
  28877. # as_fn_executable_p FILE
  28878. # -----------------------
  28879. # Test if FILE is an executable regular file.
  28880. as_fn_executable_p ()
  28881. {
  28882. test -f "$1" && test -x "$1"
  28883. } # as_fn_executable_p
  28884. as_test_x='test -x'
  28885. as_executable_p=as_fn_executable_p
  28886. # Sed expression to map a string onto a valid CPP name.
  28887. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
  28888. # Sed expression to map a string onto a valid variable name.
  28889. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
  28890. exec 6>&1
  28891. ## ----------------------------------- ##
  28892. ## Main body of $CONFIG_STATUS script. ##
  28893. ## ----------------------------------- ##
  28894. _ASEOF
  28895. test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
  28896. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28897. # Save the log message, to keep $0 and so on meaningful, and to
  28898. # report actual input values of CONFIG_FILES etc. instead of their
  28899. # values after options handling.
  28900. ac_log="
  28901. This file was extended by asterisk $as_me trunk, which was
  28902. generated by GNU Autoconf 2.69. Invocation command line was
  28903. CONFIG_FILES = $CONFIG_FILES
  28904. CONFIG_HEADERS = $CONFIG_HEADERS
  28905. CONFIG_LINKS = $CONFIG_LINKS
  28906. CONFIG_COMMANDS = $CONFIG_COMMANDS
  28907. $ $0 $@
  28908. on `(hostname || uname -n) 2>/dev/null | sed 1q`
  28909. "
  28910. _ACEOF
  28911. case $ac_config_files in *"
  28912. "*) set x $ac_config_files; shift; ac_config_files=$*;;
  28913. esac
  28914. case $ac_config_headers in *"
  28915. "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
  28916. esac
  28917. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28918. # Files that config.status was made for.
  28919. config_files="$ac_config_files"
  28920. config_headers="$ac_config_headers"
  28921. _ACEOF
  28922. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28923. ac_cs_usage="\
  28924. \`$as_me' instantiates files and other configuration actions
  28925. from templates according to the current configuration. Unless the files
  28926. and actions are specified as TAGs, all are instantiated by default.
  28927. Usage: $0 [OPTION]... [TAG]...
  28928. -h, --help print this help, then exit
  28929. -V, --version print version number and configuration settings, then exit
  28930. --config print configuration, then exit
  28931. -q, --quiet, --silent
  28932. do not print progress messages
  28933. -d, --debug don't remove temporary files
  28934. --recheck update $as_me by reconfiguring in the same conditions
  28935. --file=FILE[:TEMPLATE]
  28936. instantiate the configuration file FILE
  28937. --header=FILE[:TEMPLATE]
  28938. instantiate the configuration header FILE
  28939. Configuration files:
  28940. $config_files
  28941. Configuration headers:
  28942. $config_headers
  28943. Report bugs to <https://issues.asterisk.org>."
  28944. _ACEOF
  28945. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  28946. ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
  28947. ac_cs_version="\\
  28948. asterisk config.status trunk
  28949. configured by $0, generated by GNU Autoconf 2.69,
  28950. with options \\"\$ac_cs_config\\"
  28951. Copyright (C) 2012 Free Software Foundation, Inc.
  28952. This config.status script is free software; the Free Software Foundation
  28953. gives unlimited permission to copy, distribute and modify it."
  28954. ac_pwd='$ac_pwd'
  28955. srcdir='$srcdir'
  28956. INSTALL='$INSTALL'
  28957. AWK='$AWK'
  28958. test -n "\$AWK" || AWK=awk
  28959. _ACEOF
  28960. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  28961. # The default lists apply if the user does not specify any file.
  28962. ac_need_defaults=:
  28963. while test $# != 0
  28964. do
  28965. case $1 in
  28966. --*=?*)
  28967. ac_option=`expr "X$1" : 'X\([^=]*\)='`
  28968. ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
  28969. ac_shift=:
  28970. ;;
  28971. --*=)
  28972. ac_option=`expr "X$1" : 'X\([^=]*\)='`
  28973. ac_optarg=
  28974. ac_shift=:
  28975. ;;
  28976. *)
  28977. ac_option=$1
  28978. ac_optarg=$2
  28979. ac_shift=shift
  28980. ;;
  28981. esac
  28982. case $ac_option in
  28983. # Handling of the options.
  28984. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  28985. ac_cs_recheck=: ;;
  28986. --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
  28987. $as_echo "$ac_cs_version"; exit ;;
  28988. --config | --confi | --conf | --con | --co | --c )
  28989. $as_echo "$ac_cs_config"; exit ;;
  28990. --debug | --debu | --deb | --de | --d | -d )
  28991. debug=: ;;
  28992. --file | --fil | --fi | --f )
  28993. $ac_shift
  28994. case $ac_optarg in
  28995. *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
  28996. '') as_fn_error $? "missing file argument" ;;
  28997. esac
  28998. as_fn_append CONFIG_FILES " '$ac_optarg'"
  28999. ac_need_defaults=false;;
  29000. --header | --heade | --head | --hea )
  29001. $ac_shift
  29002. case $ac_optarg in
  29003. *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
  29004. esac
  29005. as_fn_append CONFIG_HEADERS " '$ac_optarg'"
  29006. ac_need_defaults=false;;
  29007. --he | --h)
  29008. # Conflict between --help and --header
  29009. as_fn_error $? "ambiguous option: \`$1'
  29010. Try \`$0 --help' for more information.";;
  29011. --help | --hel | -h )
  29012. $as_echo "$ac_cs_usage"; exit ;;
  29013. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  29014. | -silent | --silent | --silen | --sile | --sil | --si | --s)
  29015. ac_cs_silent=: ;;
  29016. # This is an error.
  29017. -*) as_fn_error $? "unrecognized option: \`$1'
  29018. Try \`$0 --help' for more information." ;;
  29019. *) as_fn_append ac_config_targets " $1"
  29020. ac_need_defaults=false ;;
  29021. esac
  29022. shift
  29023. done
  29024. ac_configure_extra_args=
  29025. if $ac_cs_silent; then
  29026. exec 6>/dev/null
  29027. ac_configure_extra_args="$ac_configure_extra_args --silent"
  29028. fi
  29029. _ACEOF
  29030. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29031. if \$ac_cs_recheck; then
  29032. set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
  29033. shift
  29034. \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
  29035. CONFIG_SHELL='$SHELL'
  29036. export CONFIG_SHELL
  29037. exec "\$@"
  29038. fi
  29039. _ACEOF
  29040. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29041. exec 5>>config.log
  29042. {
  29043. echo
  29044. sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
  29045. ## Running $as_me. ##
  29046. _ASBOX
  29047. $as_echo "$ac_log"
  29048. } >&5
  29049. _ACEOF
  29050. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29051. _ACEOF
  29052. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29053. # Handling of arguments.
  29054. for ac_config_target in $ac_config_targets
  29055. do
  29056. case $ac_config_target in
  29057. "include/asterisk/autoconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS include/asterisk/autoconfig.h" ;;
  29058. "build_tools/menuselect-deps") CONFIG_FILES="$CONFIG_FILES build_tools/menuselect-deps" ;;
  29059. "makeopts") CONFIG_FILES="$CONFIG_FILES makeopts" ;;
  29060. *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
  29061. esac
  29062. done
  29063. # If the user did not use the arguments to specify the items to instantiate,
  29064. # then the envvar interface is used. Set only those that are not.
  29065. # We use the long form for the default assignment because of an extremely
  29066. # bizarre bug on SunOS 4.1.3.
  29067. if $ac_need_defaults; then
  29068. test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
  29069. test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
  29070. fi
  29071. # Have a temporary directory for convenience. Make it in the build tree
  29072. # simply because there is no reason against having it here, and in addition,
  29073. # creating and moving files from /tmp can sometimes cause problems.
  29074. # Hook for its removal unless debugging.
  29075. # Note that there is a small window in which the directory will not be cleaned:
  29076. # after its creation but before its name has been assigned to `$tmp'.
  29077. $debug ||
  29078. {
  29079. tmp= ac_tmp=
  29080. trap 'exit_status=$?
  29081. : "${ac_tmp:=$tmp}"
  29082. { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
  29083. ' 0
  29084. trap 'as_fn_exit 1' 1 2 13 15
  29085. }
  29086. # Create a (secure) tmp directory for tmp files.
  29087. {
  29088. tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
  29089. test -d "$tmp"
  29090. } ||
  29091. {
  29092. tmp=./conf$$-$RANDOM
  29093. (umask 077 && mkdir "$tmp")
  29094. } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
  29095. ac_tmp=$tmp
  29096. # Set up the scripts for CONFIG_FILES section.
  29097. # No need to generate them if there are no CONFIG_FILES.
  29098. # This happens for instance with `./config.status config.h'.
  29099. if test -n "$CONFIG_FILES"; then
  29100. ac_cr=`echo X | tr X '\015'`
  29101. # On cygwin, bash can eat \r inside `` if the user requested igncr.
  29102. # But we know of no other shell where ac_cr would be empty at this
  29103. # point, so we can use a bashism as a fallback.
  29104. if test "x$ac_cr" = x; then
  29105. eval ac_cr=\$\'\\r\'
  29106. fi
  29107. ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
  29108. if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
  29109. ac_cs_awk_cr='\\r'
  29110. else
  29111. ac_cs_awk_cr=$ac_cr
  29112. fi
  29113. echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
  29114. _ACEOF
  29115. {
  29116. echo "cat >conf$$subs.awk <<_ACEOF" &&
  29117. echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
  29118. echo "_ACEOF"
  29119. } >conf$$subs.sh ||
  29120. as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
  29121. ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
  29122. ac_delim='%!_!# '
  29123. for ac_last_try in false false false false false :; do
  29124. . ./conf$$subs.sh ||
  29125. as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
  29126. ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
  29127. if test $ac_delim_n = $ac_delim_num; then
  29128. break
  29129. elif $ac_last_try; then
  29130. as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
  29131. else
  29132. ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
  29133. fi
  29134. done
  29135. rm -f conf$$subs.sh
  29136. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29137. cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
  29138. _ACEOF
  29139. sed -n '
  29140. h
  29141. s/^/S["/; s/!.*/"]=/
  29142. p
  29143. g
  29144. s/^[^!]*!//
  29145. :repl
  29146. t repl
  29147. s/'"$ac_delim"'$//
  29148. t delim
  29149. :nl
  29150. h
  29151. s/\(.\{148\}\)..*/\1/
  29152. t more1
  29153. s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
  29154. p
  29155. n
  29156. b repl
  29157. :more1
  29158. s/["\\]/\\&/g; s/^/"/; s/$/"\\/
  29159. p
  29160. g
  29161. s/.\{148\}//
  29162. t nl
  29163. :delim
  29164. h
  29165. s/\(.\{148\}\)..*/\1/
  29166. t more2
  29167. s/["\\]/\\&/g; s/^/"/; s/$/"/
  29168. p
  29169. b
  29170. :more2
  29171. s/["\\]/\\&/g; s/^/"/; s/$/"\\/
  29172. p
  29173. g
  29174. s/.\{148\}//
  29175. t delim
  29176. ' <conf$$subs.awk | sed '
  29177. /^[^""]/{
  29178. N
  29179. s/\n//
  29180. }
  29181. ' >>$CONFIG_STATUS || ac_write_fail=1
  29182. rm -f conf$$subs.awk
  29183. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29184. _ACAWK
  29185. cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
  29186. for (key in S) S_is_set[key] = 1
  29187. FS = ""
  29188. }
  29189. {
  29190. line = $ 0
  29191. nfields = split(line, field, "@")
  29192. substed = 0
  29193. len = length(field[1])
  29194. for (i = 2; i < nfields; i++) {
  29195. key = field[i]
  29196. keylen = length(key)
  29197. if (S_is_set[key]) {
  29198. value = S[key]
  29199. line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
  29200. len += length(value) + length(field[++i])
  29201. substed = 1
  29202. } else
  29203. len += 1 + keylen
  29204. }
  29205. print line
  29206. }
  29207. _ACAWK
  29208. _ACEOF
  29209. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29210. if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
  29211. sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
  29212. else
  29213. cat
  29214. fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
  29215. || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
  29216. _ACEOF
  29217. # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
  29218. # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
  29219. # trailing colons and then remove the whole line if VPATH becomes empty
  29220. # (actually we leave an empty line to preserve line numbers).
  29221. if test "x$srcdir" = x.; then
  29222. ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
  29223. h
  29224. s///
  29225. s/^/:/
  29226. s/[ ]*$/:/
  29227. s/:\$(srcdir):/:/g
  29228. s/:\${srcdir}:/:/g
  29229. s/:@srcdir@:/:/g
  29230. s/^:*//
  29231. s/:*$//
  29232. x
  29233. s/\(=[ ]*\).*/\1/
  29234. G
  29235. s/\n//
  29236. s/^[^=]*=[ ]*$//
  29237. }'
  29238. fi
  29239. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29240. fi # test -n "$CONFIG_FILES"
  29241. # Set up the scripts for CONFIG_HEADERS section.
  29242. # No need to generate them if there are no CONFIG_HEADERS.
  29243. # This happens for instance with `./config.status Makefile'.
  29244. if test -n "$CONFIG_HEADERS"; then
  29245. cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
  29246. BEGIN {
  29247. _ACEOF
  29248. # Transform confdefs.h into an awk script `defines.awk', embedded as
  29249. # here-document in config.status, that substitutes the proper values into
  29250. # config.h.in to produce config.h.
  29251. # Create a delimiter string that does not exist in confdefs.h, to ease
  29252. # handling of long lines.
  29253. ac_delim='%!_!# '
  29254. for ac_last_try in false false :; do
  29255. ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
  29256. if test -z "$ac_tt"; then
  29257. break
  29258. elif $ac_last_try; then
  29259. as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
  29260. else
  29261. ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
  29262. fi
  29263. done
  29264. # For the awk script, D is an array of macro values keyed by name,
  29265. # likewise P contains macro parameters if any. Preserve backslash
  29266. # newline sequences.
  29267. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
  29268. sed -n '
  29269. s/.\{148\}/&'"$ac_delim"'/g
  29270. t rset
  29271. :rset
  29272. s/^[ ]*#[ ]*define[ ][ ]*/ /
  29273. t def
  29274. d
  29275. :def
  29276. s/\\$//
  29277. t bsnl
  29278. s/["\\]/\\&/g
  29279. s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
  29280. D["\1"]=" \3"/p
  29281. s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
  29282. d
  29283. :bsnl
  29284. s/["\\]/\\&/g
  29285. s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
  29286. D["\1"]=" \3\\\\\\n"\\/p
  29287. t cont
  29288. s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
  29289. t cont
  29290. d
  29291. :cont
  29292. n
  29293. s/.\{148\}/&'"$ac_delim"'/g
  29294. t clear
  29295. :clear
  29296. s/\\$//
  29297. t bsnlc
  29298. s/["\\]/\\&/g; s/^/"/; s/$/"/p
  29299. d
  29300. :bsnlc
  29301. s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
  29302. b cont
  29303. ' <confdefs.h | sed '
  29304. s/'"$ac_delim"'/"\\\
  29305. "/g' >>$CONFIG_STATUS || ac_write_fail=1
  29306. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29307. for (key in D) D_is_set[key] = 1
  29308. FS = ""
  29309. }
  29310. /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
  29311. line = \$ 0
  29312. split(line, arg, " ")
  29313. if (arg[1] == "#") {
  29314. defundef = arg[2]
  29315. mac1 = arg[3]
  29316. } else {
  29317. defundef = substr(arg[1], 2)
  29318. mac1 = arg[2]
  29319. }
  29320. split(mac1, mac2, "(") #)
  29321. macro = mac2[1]
  29322. prefix = substr(line, 1, index(line, defundef) - 1)
  29323. if (D_is_set[macro]) {
  29324. # Preserve the white space surrounding the "#".
  29325. print prefix "define", macro P[macro] D[macro]
  29326. next
  29327. } else {
  29328. # Replace #undef with comments. This is necessary, for example,
  29329. # in the case of _POSIX_SOURCE, which is predefined and required
  29330. # on some systems where configure will not decide to define it.
  29331. if (defundef == "undef") {
  29332. print "/*", prefix defundef, macro, "*/"
  29333. next
  29334. }
  29335. }
  29336. }
  29337. { print }
  29338. _ACAWK
  29339. _ACEOF
  29340. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29341. as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
  29342. fi # test -n "$CONFIG_HEADERS"
  29343. eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS "
  29344. shift
  29345. for ac_tag
  29346. do
  29347. case $ac_tag in
  29348. :[FHLC]) ac_mode=$ac_tag; continue;;
  29349. esac
  29350. case $ac_mode$ac_tag in
  29351. :[FHL]*:*);;
  29352. :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
  29353. :[FH]-) ac_tag=-:-;;
  29354. :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
  29355. esac
  29356. ac_save_IFS=$IFS
  29357. IFS=:
  29358. set x $ac_tag
  29359. IFS=$ac_save_IFS
  29360. shift
  29361. ac_file=$1
  29362. shift
  29363. case $ac_mode in
  29364. :L) ac_source=$1;;
  29365. :[FH])
  29366. ac_file_inputs=
  29367. for ac_f
  29368. do
  29369. case $ac_f in
  29370. -) ac_f="$ac_tmp/stdin";;
  29371. *) # Look for the file first in the build tree, then in the source tree
  29372. # (if the path is not absolute). The absolute path cannot be DOS-style,
  29373. # because $ac_f cannot contain `:'.
  29374. test -f "$ac_f" ||
  29375. case $ac_f in
  29376. [\\/$]*) false;;
  29377. *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
  29378. esac ||
  29379. as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
  29380. esac
  29381. case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
  29382. as_fn_append ac_file_inputs " '$ac_f'"
  29383. done
  29384. # Let's still pretend it is `configure' which instantiates (i.e., don't
  29385. # use $as_me), people would be surprised to read:
  29386. # /* config.h. Generated by config.status. */
  29387. configure_input='Generated from '`
  29388. $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
  29389. `' by configure.'
  29390. if test x"$ac_file" != x-; then
  29391. configure_input="$ac_file. $configure_input"
  29392. { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
  29393. $as_echo "$as_me: creating $ac_file" >&6;}
  29394. fi
  29395. # Neutralize special characters interpreted by sed in replacement strings.
  29396. case $configure_input in #(
  29397. *\&* | *\|* | *\\* )
  29398. ac_sed_conf_input=`$as_echo "$configure_input" |
  29399. sed 's/[\\\\&|]/\\\\&/g'`;; #(
  29400. *) ac_sed_conf_input=$configure_input;;
  29401. esac
  29402. case $ac_tag in
  29403. *:-:* | *:-) cat >"$ac_tmp/stdin" \
  29404. || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
  29405. esac
  29406. ;;
  29407. esac
  29408. ac_dir=`$as_dirname -- "$ac_file" ||
  29409. $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
  29410. X"$ac_file" : 'X\(//\)[^/]' \| \
  29411. X"$ac_file" : 'X\(//\)$' \| \
  29412. X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
  29413. $as_echo X"$ac_file" |
  29414. sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
  29415. s//\1/
  29416. q
  29417. }
  29418. /^X\(\/\/\)[^/].*/{
  29419. s//\1/
  29420. q
  29421. }
  29422. /^X\(\/\/\)$/{
  29423. s//\1/
  29424. q
  29425. }
  29426. /^X\(\/\).*/{
  29427. s//\1/
  29428. q
  29429. }
  29430. s/.*/./; q'`
  29431. as_dir="$ac_dir"; as_fn_mkdir_p
  29432. ac_builddir=.
  29433. case "$ac_dir" in
  29434. .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
  29435. *)
  29436. ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  29437. # A ".." for each directory in $ac_dir_suffix.
  29438. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  29439. case $ac_top_builddir_sub in
  29440. "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  29441. *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  29442. esac ;;
  29443. esac
  29444. ac_abs_top_builddir=$ac_pwd
  29445. ac_abs_builddir=$ac_pwd$ac_dir_suffix
  29446. # for backward compatibility:
  29447. ac_top_builddir=$ac_top_build_prefix
  29448. case $srcdir in
  29449. .) # We are building in place.
  29450. ac_srcdir=.
  29451. ac_top_srcdir=$ac_top_builddir_sub
  29452. ac_abs_top_srcdir=$ac_pwd ;;
  29453. [\\/]* | ?:[\\/]* ) # Absolute name.
  29454. ac_srcdir=$srcdir$ac_dir_suffix;
  29455. ac_top_srcdir=$srcdir
  29456. ac_abs_top_srcdir=$srcdir ;;
  29457. *) # Relative name.
  29458. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
  29459. ac_top_srcdir=$ac_top_build_prefix$srcdir
  29460. ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
  29461. esac
  29462. ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
  29463. case $ac_mode in
  29464. :F)
  29465. #
  29466. # CONFIG_FILE
  29467. #
  29468. case $INSTALL in
  29469. [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
  29470. *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
  29471. esac
  29472. _ACEOF
  29473. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29474. # If the template does not know about datarootdir, expand it.
  29475. # FIXME: This hack should be removed a few years after 2.60.
  29476. ac_datarootdir_hack=; ac_datarootdir_seen=
  29477. ac_sed_dataroot='
  29478. /datarootdir/ {
  29479. p
  29480. q
  29481. }
  29482. /@datadir@/p
  29483. /@docdir@/p
  29484. /@infodir@/p
  29485. /@localedir@/p
  29486. /@mandir@/p'
  29487. case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
  29488. *datarootdir*) ac_datarootdir_seen=yes;;
  29489. *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
  29490. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
  29491. $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
  29492. _ACEOF
  29493. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29494. ac_datarootdir_hack='
  29495. s&@datadir@&$datadir&g
  29496. s&@docdir@&$docdir&g
  29497. s&@infodir@&$infodir&g
  29498. s&@localedir@&$localedir&g
  29499. s&@mandir@&$mandir&g
  29500. s&\\\${datarootdir}&$datarootdir&g' ;;
  29501. esac
  29502. _ACEOF
  29503. # Neutralize VPATH when `$srcdir' = `.'.
  29504. # Shell code in configure.ac might set extrasub.
  29505. # FIXME: do we really want to maintain this feature?
  29506. cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  29507. ac_sed_extra="$ac_vpsub
  29508. $extrasub
  29509. _ACEOF
  29510. cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  29511. :t
  29512. /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
  29513. s|@configure_input@|$ac_sed_conf_input|;t t
  29514. s&@top_builddir@&$ac_top_builddir_sub&;t t
  29515. s&@top_build_prefix@&$ac_top_build_prefix&;t t
  29516. s&@srcdir@&$ac_srcdir&;t t
  29517. s&@abs_srcdir@&$ac_abs_srcdir&;t t
  29518. s&@top_srcdir@&$ac_top_srcdir&;t t
  29519. s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
  29520. s&@builddir@&$ac_builddir&;t t
  29521. s&@abs_builddir@&$ac_abs_builddir&;t t
  29522. s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
  29523. s&@INSTALL@&$ac_INSTALL&;t t
  29524. $ac_datarootdir_hack
  29525. "
  29526. eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
  29527. >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  29528. test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
  29529. { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
  29530. { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
  29531. "$ac_tmp/out"`; test -z "$ac_out"; } &&
  29532. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
  29533. which seems to be undefined. Please make sure it is defined" >&5
  29534. $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
  29535. which seems to be undefined. Please make sure it is defined" >&2;}
  29536. rm -f "$ac_tmp/stdin"
  29537. case $ac_file in
  29538. -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
  29539. *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
  29540. esac \
  29541. || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  29542. ;;
  29543. :H)
  29544. #
  29545. # CONFIG_HEADER
  29546. #
  29547. if test x"$ac_file" != x-; then
  29548. {
  29549. $as_echo "/* $configure_input */" \
  29550. && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
  29551. } >"$ac_tmp/config.h" \
  29552. || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  29553. if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
  29554. { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
  29555. $as_echo "$as_me: $ac_file is unchanged" >&6;}
  29556. else
  29557. rm -f "$ac_file"
  29558. mv "$ac_tmp/config.h" "$ac_file" \
  29559. || as_fn_error $? "could not create $ac_file" "$LINENO" 5
  29560. fi
  29561. else
  29562. $as_echo "/* $configure_input */" \
  29563. && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
  29564. || as_fn_error $? "could not create -" "$LINENO" 5
  29565. fi
  29566. ;;
  29567. esac
  29568. done # for ac_tag
  29569. as_fn_exit 0
  29570. _ACEOF
  29571. ac_clean_files=$ac_clean_files_save
  29572. test $ac_write_fail = 0 ||
  29573. as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
  29574. # configure is writing to config.log, and then calls config.status.
  29575. # config.status does its own redirection, appending to config.log.
  29576. # Unfortunately, on DOS this fails, as config.log is still kept open
  29577. # by configure, so config.status won't be able to write to it; its
  29578. # output is simply discarded. So we exec the FD to /dev/null,
  29579. # effectively closing config.log, so it can be properly (re)opened and
  29580. # appended to by config.status. When coming back to configure, we
  29581. # need to make the FD available again.
  29582. if test "$no_create" != yes; then
  29583. ac_cs_success=:
  29584. ac_config_status_args=
  29585. test "$silent" = yes &&
  29586. ac_config_status_args="$ac_config_status_args --quiet"
  29587. exec 5>/dev/null
  29588. $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
  29589. exec 5>>config.log
  29590. # Use ||, not &&, to avoid exiting from the if with $? = 1, which
  29591. # would make configure fail if this is the last instruction.
  29592. $ac_cs_success || as_fn_exit 1
  29593. fi
  29594. if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
  29595. { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
  29596. $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
  29597. fi
  29598. ${ac_cv_path_EGREP} 'CURSES|GTK2|OSARCH|NEWT' makeopts > makeopts.acbak2
  29599. if test "x${ac_cv_path_CMP}" = "x:"; then
  29600. ( cd `pwd`/menuselect && ./configure )
  29601. else if ${ac_cv_path_CMP} -s makeopts.acbak makeopts.acbak2; then : ; else
  29602. ( cd `pwd`/menuselect && ./configure )
  29603. fi ; fi
  29604. rm makeopts.acbak makeopts.acbak2
  29605. if test "x${silent}" != "xyes" ; then
  29606. echo
  29607. echo " .\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$=.. "
  29608. echo " .\$7\$7.. .7\$\$7:. "
  29609. echo " .\$\$:. ,\$7.7 "
  29610. echo " .\$7. 7\$\$\$\$ .\$\$77 "
  29611. echo " ..\$\$. \$\$\$\$\$ .\$\$\$7 "
  29612. echo " ..7\$ .?. \$\$\$\$\$ .?. 7\$\$\$."
  29613. echo " \$.\$. .\$\$\$7. \$\$\$\$7 .7\$\$\$. .\$\$\$."
  29614. echo " .777. .\$\$\$\$\$\$77\$\$\$77\$\$\$\$\$7. \$\$\$,"
  29615. echo " \$\$\$~ .7\$\$\$\$\$\$\$\$\$\$\$\$\$7. .\$\$\$."
  29616. echo ".\$\$7 .7\$\$\$\$\$\$\$7: ?\$\$\$."
  29617. echo "\$\$\$ ?7\$\$\$\$\$\$\$\$\$\$I .\$\$\$7 "
  29618. echo "\$\$\$ .7\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$ :\$\$\$. "
  29619. echo "\$\$\$ \$\$\$\$\$\$7\$\$\$\$\$\$\$\$\$\$\$\$ .\$\$\$. "
  29620. echo "\$\$\$ \$\$\$ 7\$\$\$7 .\$\$\$ .\$\$\$. "
  29621. echo "\$\$\$\$ \$\$\$\$7 .\$\$\$. "
  29622. echo "7\$\$\$7 7\$\$\$\$ 7\$\$\$ "
  29623. echo " \$\$\$\$\$ \$\$\$ "
  29624. echo " \$\$\$\$7. \$\$ (TM) "
  29625. echo " \$\$\$\$\$\$\$. .7\$\$\$\$\$\$ \$\$ "
  29626. echo " \$\$\$\$\$\$\$\$\$\$\$\$7\$\$\$\$\$\$\$\$\$.\$\$\$\$\$\$ "
  29627. echo " \$\$\$\$\$\$\$\$\$\$\$\$\$\$\$\$. "
  29628. echo
  29629. fi
  29630. if test "x${AST_IODBC_FOUND}" = "xyes"; then
  29631. echo "WARNING: iodbc libs/headers found!"
  29632. echo
  29633. echo " If you plan to use ODBC functionality, you should consider"
  29634. echo " switching to unixodbc instead."
  29635. echo " See: https://issues.asterisk.org/jira/browse/ASTERISK-22459"
  29636. echo
  29637. fi
  29638. { $as_echo "$as_me:${as_lineno-$LINENO}: Package configured for: " >&5
  29639. $as_echo "$as_me: Package configured for: " >&6;}
  29640. { $as_echo "$as_me:${as_lineno-$LINENO}: OS type : $host_os" >&5
  29641. $as_echo "$as_me: OS type : $host_os" >&6;}
  29642. { $as_echo "$as_me:${as_lineno-$LINENO}: Host CPU : $host_cpu" >&5
  29643. $as_echo "$as_me: Host CPU : $host_cpu" >&6;}
  29644. { $as_echo "$as_me:${as_lineno-$LINENO}: build-cpu:vendor:os: $build_cpu : $build_vendor : $build_os :" >&5
  29645. $as_echo "$as_me: build-cpu:vendor:os: $build_cpu : $build_vendor : $build_os :" >&6;}
  29646. { $as_echo "$as_me:${as_lineno-$LINENO}: host-cpu:vendor:os: $host_cpu : $host_vendor : $host_os :" >&5
  29647. $as_echo "$as_me: host-cpu:vendor:os: $host_cpu : $host_vendor : $host_os :" >&6;}
  29648. if test "${cross_compiling}" = "yes"; then
  29649. { $as_echo "$as_me:${as_lineno-$LINENO}: Cross Compilation = YES" >&5
  29650. $as_echo "$as_me: Cross Compilation = YES" >&6;}
  29651. fi