configure 408 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949
  1. #! /bin/sh
  2. # Guess values for system-dependent variables and create Makefiles.
  3. # Generated automatically using autoconf version 2.13
  4. # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
  5. #
  6. # This configure script is free software; the Free Software Foundation
  7. # gives unlimited permission to copy, distribute and modify it.
  8. # Defaults:
  9. ac_help=
  10. ac_default_prefix=/usr/local
  11. # Any additions from configure.in:
  12. ac_default_prefix=/usr/local
  13. ac_help="$ac_help
  14. --enable-macosx-app create a MacOSX application"
  15. ac_help="$ac_help
  16. --enable-shared build and link with shared libraries [--enable-shared]"
  17. ac_help="$ac_help
  18. --enable-64bit enable 64bit support (where applicable)"
  19. ac_help="$ac_help
  20. --enable-64bit-vis enable 64bit Sparc VIS support"
  21. ac_help="$ac_help
  22. --enable-w11 use W11 library for Windows X11 emulation"
  23. ac_help="$ac_help
  24. --with-cxx support C++ functionality (default: no)"
  25. ac_help="$ac_help
  26. --with-jpeg support JPEG functionality (default: yes)"
  27. ac_help="$ac_help
  28. --with-tiff support TIFF functionality (default: yes)"
  29. ac_help="$ac_help
  30. --with-png support PNG functionality (default: yes)"
  31. ac_help="$ac_help
  32. --with-tcltk support Tcl/Tk functionality (default: yes)"
  33. ac_help="$ac_help
  34. --with-postgres support PostgreSQL functionality (default: no)"
  35. ac_help="$ac_help
  36. --with-mysql support MySQL functionality (default: no)"
  37. ac_help="$ac_help
  38. --with-sqlite support SQLite functionality (default: no)"
  39. ac_help="$ac_help
  40. --with-ffmpeg support FFMPEG functionality (default: no)"
  41. ac_help="$ac_help
  42. --with-opengl support OpenGL functionality (default: yes)"
  43. ac_help="$ac_help
  44. --with-odbc support ODBC functionality (default: no)"
  45. ac_help="$ac_help
  46. --with-fftw support FFTW functionality (default: yes)"
  47. ac_help="$ac_help
  48. --with-blas support BLAS functionality (default: no)"
  49. ac_help="$ac_help
  50. --with-lapack support LAPACK functionality (default: no)"
  51. ac_help="$ac_help
  52. --with-cairo support Cairo functionality (default: yes)"
  53. ac_help="$ac_help
  54. --with-freetype support FreeType functionality (default: yes)"
  55. ac_help="$ac_help
  56. --with-nls support NLS functionality (default: no)"
  57. ac_help="$ac_help
  58. --with-readline support Readline functionality (default: no)"
  59. ac_help="$ac_help
  60. --with-opendwg support openDWG functionality (default: no)"
  61. ac_help="$ac_help
  62. --with-regex support regex functionality (default: yes)"
  63. ac_help="$ac_help
  64. --with-pthread support POSIX threads functionality (default: no)"
  65. ac_help="$ac_help
  66. --with-gdal[=path/gdal-config] enable GDAL/OGR support (gdal-config with path, \
  67. e.g. '--with-gdal=/usr/local/bin/gdal-config')"
  68. ac_help="$ac_help
  69. --with-python[=path/python-config] enable support for Python SWIG bindings and wxGUI Python extensions \
  70. (python-config with path, e.g. '--with-python=/usr/bin/python2.5-config', \
  71. default: no)"
  72. ac_help="$ac_help
  73. --with-wxwidgets[=path/wx-config] enable wxWidgets support (wx-config with path, \
  74. e.g. '--with-wxwidgets=/usr/local/bin/wx-config', default: no)"
  75. ac_help="$ac_help
  76. --with-geos[=path/geos-config] enable GEOS support (geos-config with path, \
  77. e.g. '--with-geos=/usr/local/bin/geos-config', default: no)"
  78. ac_help="$ac_help
  79. --with-includes=DIRS site include files are in DIRS"
  80. ac_help="$ac_help
  81. --with-libs=DIRS site library files are in DIRS"
  82. ac_help="$ac_help
  83. --with-zlib-includes=DIRS
  84. zlib include files are in DIRS"
  85. ac_help="$ac_help
  86. --with-zlib-libs=DIRS zlib library files are in DIRS"
  87. ac_help="$ac_help
  88. --with-readline-includes=DIRS
  89. Readline include files are in DIRS"
  90. ac_help="$ac_help
  91. --with-readline-libs=DIRS
  92. Readline library files are in DIRS"
  93. ac_help="$ac_help
  94. --with-jpeg-includes=DIRS
  95. JPEG include files are in DIRS"
  96. ac_help="$ac_help
  97. --with-jpeg-libs=DIRS JPEG library files are in DIRS"
  98. ac_help="$ac_help
  99. --with-tiff-includes=DIRS
  100. TIFF include files are in DIRS"
  101. ac_help="$ac_help
  102. --with-tiff-libs=DIRS TIFF library files are in DIRS"
  103. ac_help="$ac_help
  104. --with-png-includes=DIRS
  105. PNG include files are in DIRS"
  106. ac_help="$ac_help
  107. --with-png-libs=DIRS PNG library files are in DIRS"
  108. ac_help="$ac_help
  109. --with-tcltk-includes=DIRS
  110. Tcl/Tk include files are in DIRS"
  111. ac_help="$ac_help
  112. --with-tcltk-libs=DIRS Tcl/Tk library files are in DIRS"
  113. ac_help="$ac_help
  114. --with-postgres-includes=DIRS
  115. PostgreSQL include files are in DIRS"
  116. ac_help="$ac_help
  117. --with-postgres-libs=DIRS
  118. PostgreSQL library files are in DIRS"
  119. ac_help="$ac_help
  120. --with-mysql-includes=DIRS
  121. MySQL include files are in DIRS"
  122. ac_help="$ac_help
  123. --with-mysql-libs=DIRS MySQL library files are in DIRS"
  124. ac_help="$ac_help
  125. --with-sqlite-includes=DIRS
  126. SQLite include files are in DIRS"
  127. ac_help="$ac_help
  128. --with-sqlite-libs=DIRS SQLite library files are in DIRS"
  129. ac_help="$ac_help
  130. --with-ffmpeg-includes=DIRS
  131. FFMPEG include files are in DIRS"
  132. ac_help="$ac_help
  133. --with-ffmpeg-libs=DIRS FFMPEG library files are in DIRS"
  134. ac_help="$ac_help
  135. --with-opengl-includes=DIRS
  136. OpenGL include files are in DIRS"
  137. ac_help="$ac_help
  138. --with-opengl-libs=DIRS OpenGL library files are in DIRS"
  139. ac_help="$ac_help
  140. --with-opengl-framework=DIR
  141. OpenGL framework is in DIR"
  142. ac_help="$ac_help
  143. --with-odbc-includes=DIRS
  144. ODBC include files are in DIRS"
  145. ac_help="$ac_help
  146. --with-odbc-libs=DIRS ODBC library files are in DIRS"
  147. ac_help="$ac_help
  148. --with-fftw-includes=DIRS
  149. FFTW include files are in DIRS"
  150. ac_help="$ac_help
  151. --with-fftw-libs=DIRS FFTW library files are in DIRS"
  152. ac_help="$ac_help
  153. --with-blas-includes=DIRS
  154. BLAS include files are in DIRS"
  155. ac_help="$ac_help
  156. --with-blas-libs=DIRS BLAS library files are in DIRS"
  157. ac_help="$ac_help
  158. --with-lapack-includes=DIRS
  159. LAPACK include files are in DIRS"
  160. ac_help="$ac_help
  161. --with-lapack-libs=DIRS LAPACK library files are in DIRS"
  162. ac_help="$ac_help
  163. --with-cairo-includes=DIRS
  164. cairo include files are in DIRS"
  165. ac_help="$ac_help
  166. --with-cairo-libs=DIRS cairo library files are in DIRS"
  167. ac_help="$ac_help
  168. --with-cairo-ldflags=FLAGS
  169. cairo needs FLAGS when linking"
  170. ac_help="$ac_help
  171. --with-freetype-includes=DIRS
  172. FreeType include files are in DIRS"
  173. ac_help="$ac_help
  174. --with-freetype-libs=DIRS
  175. FreeType library files are in DIRS"
  176. ac_help="$ac_help
  177. --with-proj-includes=DIRS
  178. External PROJ.4 include files are in DIRS"
  179. ac_help="$ac_help
  180. --with-proj-libs=DIRS External PROJ.4 library files are in DIRS"
  181. ac_help="$ac_help
  182. --with-proj-share=DIR External PROJ.4 data files are in DIR"
  183. ac_help="$ac_help
  184. --with-opendwg-includes=DIRS
  185. openDWG include files are in DIRS"
  186. ac_help="$ac_help
  187. --with-opendwg-libs=DIRS
  188. openDWG library files are in DIRS"
  189. ac_help="$ac_help
  190. --with-regex-includes=DIRS
  191. regex include files are in DIRS"
  192. ac_help="$ac_help
  193. --with-regex-libs=DIRS regex library files are in DIRS"
  194. ac_help="$ac_help
  195. --with-pthread-includes=DIRS
  196. POSIX threads include files are in DIRS"
  197. ac_help="$ac_help
  198. --with-pthread-libs=DIRS
  199. POSIX threads library files are in DIRS"
  200. ac_help="$ac_help
  201. --with-x use the X Window System"
  202. ac_help="$ac_help
  203. --enable-largefile enable support for large files (LFS)"
  204. # Initialize some variables set by options.
  205. # The variables have the same names as the options, with
  206. # dashes changed to underlines.
  207. build=NONE
  208. cache_file=./config.cache
  209. exec_prefix=NONE
  210. host=NONE
  211. no_create=
  212. nonopt=NONE
  213. no_recursion=
  214. prefix=NONE
  215. program_prefix=NONE
  216. program_suffix=NONE
  217. program_transform_name=s,x,x,
  218. silent=
  219. site=
  220. srcdir=
  221. target=NONE
  222. verbose=
  223. x_includes=NONE
  224. x_libraries=NONE
  225. bindir='${exec_prefix}/bin'
  226. sbindir='${exec_prefix}/sbin'
  227. libexecdir='${exec_prefix}/libexec'
  228. datadir='${prefix}/share'
  229. sysconfdir='${prefix}/etc'
  230. sharedstatedir='${prefix}/com'
  231. localstatedir='${prefix}/var'
  232. libdir='${exec_prefix}/lib'
  233. includedir='${prefix}/include'
  234. oldincludedir='/usr/include'
  235. infodir='${prefix}/info'
  236. mandir='${prefix}/man'
  237. # Initialize some other variables.
  238. subdirs=
  239. MFLAGS= MAKEFLAGS=
  240. SHELL=${CONFIG_SHELL-/bin/sh}
  241. # Maximum number of lines to put in a shell here document.
  242. ac_max_here_lines=12
  243. ac_prev=
  244. for ac_option
  245. do
  246. # If the previous option needs an argument, assign it.
  247. if test -n "$ac_prev"; then
  248. eval "$ac_prev=\$ac_option"
  249. ac_prev=
  250. continue
  251. fi
  252. case "$ac_option" in
  253. -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  254. *) ac_optarg= ;;
  255. esac
  256. # Accept the important Cygnus configure options, so we can diagnose typos.
  257. case "$ac_option" in
  258. -bindir | --bindir | --bindi | --bind | --bin | --bi)
  259. ac_prev=bindir ;;
  260. -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
  261. bindir="$ac_optarg" ;;
  262. -build | --build | --buil | --bui | --bu)
  263. ac_prev=build ;;
  264. -build=* | --build=* | --buil=* | --bui=* | --bu=*)
  265. build="$ac_optarg" ;;
  266. -cache-file | --cache-file | --cache-fil | --cache-fi \
  267. | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
  268. ac_prev=cache_file ;;
  269. -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  270. | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
  271. cache_file="$ac_optarg" ;;
  272. -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
  273. ac_prev=datadir ;;
  274. -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
  275. | --da=*)
  276. datadir="$ac_optarg" ;;
  277. -disable-* | --disable-*)
  278. ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
  279. # Reject names that are not valid shell variable names.
  280. if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
  281. { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  282. fi
  283. ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  284. eval "enable_${ac_feature}=no" ;;
  285. -enable-* | --enable-*)
  286. ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
  287. # Reject names that are not valid shell variable names.
  288. if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
  289. { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
  290. fi
  291. ac_feature=`echo $ac_feature| sed 's/-/_/g'`
  292. case "$ac_option" in
  293. *=*) ;;
  294. *) ac_optarg=yes ;;
  295. esac
  296. eval "enable_${ac_feature}='$ac_optarg'" ;;
  297. -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  298. | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  299. | --exec | --exe | --ex)
  300. ac_prev=exec_prefix ;;
  301. -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  302. | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  303. | --exec=* | --exe=* | --ex=*)
  304. exec_prefix="$ac_optarg" ;;
  305. -gas | --gas | --ga | --g)
  306. # Obsolete; use --with-gas.
  307. with_gas=yes ;;
  308. -help | --help | --hel | --he)
  309. # Omit some internal or obsolete options to make the list less imposing.
  310. # This message is too long to be a string in the A/UX 3.1 sh.
  311. cat << EOF
  312. Usage: configure [options] [host]
  313. Options: [defaults in brackets after descriptions]
  314. Configuration:
  315. --cache-file=FILE cache test results in FILE
  316. --help print this message
  317. --no-create do not create output files
  318. --quiet, --silent do not print \`checking...' messages
  319. --version print the version of autoconf that created configure
  320. Directory and file names:
  321. --prefix=PREFIX install architecture-independent files in PREFIX
  322. [$ac_default_prefix]
  323. --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
  324. [same as prefix]
  325. --bindir=DIR user executables in DIR [EPREFIX/bin]
  326. --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
  327. --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
  328. --datadir=DIR read-only architecture-independent data in DIR
  329. [PREFIX/share]
  330. --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
  331. --sharedstatedir=DIR modifiable architecture-independent data in DIR
  332. [PREFIX/com]
  333. --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
  334. --libdir=DIR object code libraries in DIR [EPREFIX/lib]
  335. --includedir=DIR C header files in DIR [PREFIX/include]
  336. --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
  337. --infodir=DIR info documentation in DIR [PREFIX/info]
  338. --mandir=DIR man documentation in DIR [PREFIX/man]
  339. --srcdir=DIR find the sources in DIR [configure dir or ..]
  340. --program-prefix=PREFIX prepend PREFIX to installed program names
  341. --program-suffix=SUFFIX append SUFFIX to installed program names
  342. --program-transform-name=PROGRAM
  343. run sed PROGRAM on installed program names
  344. EOF
  345. cat << EOF
  346. Host type:
  347. --build=BUILD configure for building on BUILD [BUILD=HOST]
  348. --host=HOST configure for HOST [guessed]
  349. --target=TARGET configure for TARGET [TARGET=HOST]
  350. Features and packages:
  351. --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
  352. --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
  353. --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
  354. --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
  355. --x-includes=DIR X include files are in DIR
  356. --x-libraries=DIR X library files are in DIR
  357. EOF
  358. if test -n "$ac_help"; then
  359. echo "--enable and --with options recognized:$ac_help"
  360. fi
  361. exit 0 ;;
  362. -host | --host | --hos | --ho)
  363. ac_prev=host ;;
  364. -host=* | --host=* | --hos=* | --ho=*)
  365. host="$ac_optarg" ;;
  366. -includedir | --includedir | --includedi | --included | --include \
  367. | --includ | --inclu | --incl | --inc)
  368. ac_prev=includedir ;;
  369. -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  370. | --includ=* | --inclu=* | --incl=* | --inc=*)
  371. includedir="$ac_optarg" ;;
  372. -infodir | --infodir | --infodi | --infod | --info | --inf)
  373. ac_prev=infodir ;;
  374. -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
  375. infodir="$ac_optarg" ;;
  376. -libdir | --libdir | --libdi | --libd)
  377. ac_prev=libdir ;;
  378. -libdir=* | --libdir=* | --libdi=* | --libd=*)
  379. libdir="$ac_optarg" ;;
  380. -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  381. | --libexe | --libex | --libe)
  382. ac_prev=libexecdir ;;
  383. -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  384. | --libexe=* | --libex=* | --libe=*)
  385. libexecdir="$ac_optarg" ;;
  386. -localstatedir | --localstatedir | --localstatedi | --localstated \
  387. | --localstate | --localstat | --localsta | --localst \
  388. | --locals | --local | --loca | --loc | --lo)
  389. ac_prev=localstatedir ;;
  390. -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  391. | --localstate=* | --localstat=* | --localsta=* | --localst=* \
  392. | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
  393. localstatedir="$ac_optarg" ;;
  394. -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
  395. ac_prev=mandir ;;
  396. -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
  397. mandir="$ac_optarg" ;;
  398. -nfp | --nfp | --nf)
  399. # Obsolete; use --without-fp.
  400. with_fp=no ;;
  401. -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  402. | --no-cr | --no-c)
  403. no_create=yes ;;
  404. -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  405. | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
  406. no_recursion=yes ;;
  407. -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  408. | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  409. | --oldin | --oldi | --old | --ol | --o)
  410. ac_prev=oldincludedir ;;
  411. -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  412. | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  413. | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
  414. oldincludedir="$ac_optarg" ;;
  415. -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
  416. ac_prev=prefix ;;
  417. -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
  418. prefix="$ac_optarg" ;;
  419. -program-prefix | --program-prefix | --program-prefi | --program-pref \
  420. | --program-pre | --program-pr | --program-p)
  421. ac_prev=program_prefix ;;
  422. -program-prefix=* | --program-prefix=* | --program-prefi=* \
  423. | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
  424. program_prefix="$ac_optarg" ;;
  425. -program-suffix | --program-suffix | --program-suffi | --program-suff \
  426. | --program-suf | --program-su | --program-s)
  427. ac_prev=program_suffix ;;
  428. -program-suffix=* | --program-suffix=* | --program-suffi=* \
  429. | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
  430. program_suffix="$ac_optarg" ;;
  431. -program-transform-name | --program-transform-name \
  432. | --program-transform-nam | --program-transform-na \
  433. | --program-transform-n | --program-transform- \
  434. | --program-transform | --program-transfor \
  435. | --program-transfo | --program-transf \
  436. | --program-trans | --program-tran \
  437. | --progr-tra | --program-tr | --program-t)
  438. ac_prev=program_transform_name ;;
  439. -program-transform-name=* | --program-transform-name=* \
  440. | --program-transform-nam=* | --program-transform-na=* \
  441. | --program-transform-n=* | --program-transform-=* \
  442. | --program-transform=* | --program-transfor=* \
  443. | --program-transfo=* | --program-transf=* \
  444. | --program-trans=* | --program-tran=* \
  445. | --progr-tra=* | --program-tr=* | --program-t=*)
  446. program_transform_name="$ac_optarg" ;;
  447. -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  448. | -silent | --silent | --silen | --sile | --sil)
  449. silent=yes ;;
  450. -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
  451. ac_prev=sbindir ;;
  452. -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  453. | --sbi=* | --sb=*)
  454. sbindir="$ac_optarg" ;;
  455. -sharedstatedir | --sharedstatedir | --sharedstatedi \
  456. | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  457. | --sharedst | --shareds | --shared | --share | --shar \
  458. | --sha | --sh)
  459. ac_prev=sharedstatedir ;;
  460. -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  461. | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  462. | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  463. | --sha=* | --sh=*)
  464. sharedstatedir="$ac_optarg" ;;
  465. -site | --site | --sit)
  466. ac_prev=site ;;
  467. -site=* | --site=* | --sit=*)
  468. site="$ac_optarg" ;;
  469. -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
  470. ac_prev=srcdir ;;
  471. -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
  472. srcdir="$ac_optarg" ;;
  473. -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  474. | --syscon | --sysco | --sysc | --sys | --sy)
  475. ac_prev=sysconfdir ;;
  476. -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  477. | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
  478. sysconfdir="$ac_optarg" ;;
  479. -target | --target | --targe | --targ | --tar | --ta | --t)
  480. ac_prev=target ;;
  481. -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
  482. target="$ac_optarg" ;;
  483. -v | -verbose | --verbose | --verbos | --verbo | --verb)
  484. verbose=yes ;;
  485. -version | --version | --versio | --versi | --vers)
  486. echo "configure generated by autoconf version 2.13"
  487. exit 0 ;;
  488. -with-* | --with-*)
  489. ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
  490. # Reject names that are not valid shell variable names.
  491. if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
  492. { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  493. fi
  494. ac_package=`echo $ac_package| sed 's/-/_/g'`
  495. case "$ac_option" in
  496. *=*) ;;
  497. *) ac_optarg=yes ;;
  498. esac
  499. eval "with_${ac_package}='$ac_optarg'" ;;
  500. -without-* | --without-*)
  501. ac_package=`echo $ac_option|sed -e 's/-*without-//'`
  502. # Reject names that are not valid shell variable names.
  503. if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
  504. { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
  505. fi
  506. ac_package=`echo $ac_package| sed 's/-/_/g'`
  507. eval "with_${ac_package}=no" ;;
  508. --x)
  509. # Obsolete; use --with-x.
  510. with_x=yes ;;
  511. -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  512. | --x-incl | --x-inc | --x-in | --x-i)
  513. ac_prev=x_includes ;;
  514. -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  515. | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
  516. x_includes="$ac_optarg" ;;
  517. -x-libraries | --x-libraries | --x-librarie | --x-librari \
  518. | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
  519. ac_prev=x_libraries ;;
  520. -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  521. | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
  522. x_libraries="$ac_optarg" ;;
  523. -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
  524. ;;
  525. *)
  526. if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
  527. echo "configure: warning: $ac_option: invalid host type" 1>&2
  528. fi
  529. if test "x$nonopt" != xNONE; then
  530. { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
  531. fi
  532. nonopt="$ac_option"
  533. ;;
  534. esac
  535. done
  536. if test -n "$ac_prev"; then
  537. { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
  538. fi
  539. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  540. # File descriptor usage:
  541. # 0 standard input
  542. # 1 file creation
  543. # 2 errors and warnings
  544. # 3 some systems may open it to /dev/tty
  545. # 4 used on the Kubota Titan
  546. # 6 checking for... messages and results
  547. # 5 compiler messages saved in config.log
  548. if test "$silent" = yes; then
  549. exec 6>/dev/null
  550. else
  551. exec 6>&1
  552. fi
  553. exec 5>./config.log
  554. echo "\
  555. This file contains any messages produced by compilers while
  556. running configure, to aid debugging if configure makes a mistake.
  557. " 1>&5
  558. # Strip out --no-create and --no-recursion so they do not pile up.
  559. # Also quote any args containing shell metacharacters.
  560. ac_configure_args=
  561. for ac_arg
  562. do
  563. case "$ac_arg" in
  564. -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  565. | --no-cr | --no-c) ;;
  566. -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  567. | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  568. *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  569. ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  570. *) ac_configure_args="$ac_configure_args $ac_arg" ;;
  571. esac
  572. done
  573. # NLS nuisances.
  574. # Only set these to C if already set. These must not be set unconditionally
  575. # because not all systems understand e.g. LANG=C (notably SCO).
  576. # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
  577. # Non-C LC_CTYPE values break the ctype check.
  578. if test "${LANG+set}" = set; then LANG=C; export LANG; fi
  579. if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
  580. if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
  581. if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
  582. # confdefs.h avoids OS command line length limits that DEFS can exceed.
  583. rm -rf conftest* confdefs.h
  584. # AIX cpp loses on an empty file, so make sure it contains at least a newline.
  585. echo > confdefs.h
  586. # A filename unique to this package, relative to the directory that
  587. # configure is in, which we can look for to find out if srcdir is correct.
  588. ac_unique_file=configure.in
  589. # Find the source files, if location was not specified.
  590. if test -z "$srcdir"; then
  591. ac_srcdir_defaulted=yes
  592. # Try the directory containing this script, then its parent.
  593. ac_prog=$0
  594. ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  595. test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
  596. srcdir=$ac_confdir
  597. if test ! -r $srcdir/$ac_unique_file; then
  598. srcdir=..
  599. fi
  600. else
  601. ac_srcdir_defaulted=no
  602. fi
  603. if test ! -r $srcdir/$ac_unique_file; then
  604. if test "$ac_srcdir_defaulted" = yes; then
  605. { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
  606. else
  607. { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
  608. fi
  609. fi
  610. srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
  611. # Prefer explicitly selected file to automatically selected ones.
  612. if test -z "$CONFIG_SITE"; then
  613. if test "x$prefix" != xNONE; then
  614. CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  615. else
  616. CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  617. fi
  618. fi
  619. for ac_site_file in $CONFIG_SITE; do
  620. if test -r "$ac_site_file"; then
  621. echo "loading site script $ac_site_file"
  622. . "$ac_site_file"
  623. fi
  624. done
  625. ac_ext=c
  626. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  627. ac_cpp='$CPP $CPPFLAGS'
  628. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  629. ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  630. cross_compiling=$ac_cv_prog_cc_cross
  631. ac_exeext=
  632. ac_objext=o
  633. if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  634. # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  635. if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
  636. ac_n= ac_c='
  637. ' ac_t=' '
  638. else
  639. ac_n=-n ac_c= ac_t=
  640. fi
  641. else
  642. ac_n= ac_c='\c' ac_t=
  643. fi
  644. ac_aux_dir=
  645. for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  646. if test -f $ac_dir/install-sh; then
  647. ac_aux_dir=$ac_dir
  648. ac_install_sh="$ac_aux_dir/install-sh -c"
  649. break
  650. elif test -f $ac_dir/install.sh; then
  651. ac_aux_dir=$ac_dir
  652. ac_install_sh="$ac_aux_dir/install.sh -c"
  653. break
  654. fi
  655. done
  656. if test -z "$ac_aux_dir"; then
  657. { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
  658. fi
  659. ac_config_guess=$ac_aux_dir/config.guess
  660. ac_config_sub=$ac_aux_dir/config.sub
  661. ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
  662. # Make sure we can run config.sub.
  663. if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
  664. else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
  665. fi
  666. echo $ac_n "checking host system type""... $ac_c" 1>&6
  667. echo "configure:739: checking host system type" >&5
  668. host_alias=$host
  669. case "$host_alias" in
  670. NONE)
  671. case $nonopt in
  672. NONE)
  673. if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
  674. else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
  675. fi ;;
  676. *) host_alias=$nonopt ;;
  677. esac ;;
  678. esac
  679. host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
  680. host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
  681. host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
  682. host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
  683. echo "$ac_t""$host" 1>&6
  684. # Extract the first word of "gcc", so it can be a program name with args.
  685. set dummy gcc; ac_word=$2
  686. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  687. echo "configure:762: checking for $ac_word" >&5
  688. if test -n "$CC"; then
  689. ac_cv_prog_CC="$CC" # Let the user override the test.
  690. else
  691. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  692. ac_dummy="$PATH"
  693. for ac_dir in $ac_dummy; do
  694. test -z "$ac_dir" && ac_dir=.
  695. if test -f $ac_dir/$ac_word; then
  696. ac_cv_prog_CC="gcc"
  697. break
  698. fi
  699. done
  700. IFS="$ac_save_ifs"
  701. fi
  702. CC="$ac_cv_prog_CC"
  703. if test -n "$CC"; then
  704. echo "$ac_t""$CC" 1>&6
  705. else
  706. echo "$ac_t""no" 1>&6
  707. fi
  708. if test -z "$CC"; then
  709. # Extract the first word of "cc", so it can be a program name with args.
  710. set dummy cc; ac_word=$2
  711. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  712. echo "configure:789: checking for $ac_word" >&5
  713. if test -n "$CC"; then
  714. ac_cv_prog_CC="$CC" # Let the user override the test.
  715. else
  716. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  717. ac_prog_rejected=no
  718. ac_dummy="$PATH"
  719. for ac_dir in $ac_dummy; do
  720. test -z "$ac_dir" && ac_dir=.
  721. if test -f $ac_dir/$ac_word; then
  722. if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
  723. ac_prog_rejected=yes
  724. continue
  725. fi
  726. ac_cv_prog_CC="cc"
  727. break
  728. fi
  729. done
  730. IFS="$ac_save_ifs"
  731. if test $ac_prog_rejected = yes; then
  732. # We found a bogon in the path, so make sure we never use it.
  733. set dummy $ac_cv_prog_CC
  734. shift
  735. if test $# -gt 0; then
  736. # We chose a different compiler from the bogus one.
  737. # However, it has the same basename, so the bogon will be chosen
  738. # first if we set CC to just the basename; use the full file name.
  739. shift
  740. set dummy "$ac_dir/$ac_word" "$@"
  741. shift
  742. ac_cv_prog_CC="$@"
  743. fi
  744. fi
  745. fi
  746. CC="$ac_cv_prog_CC"
  747. if test -n "$CC"; then
  748. echo "$ac_t""$CC" 1>&6
  749. else
  750. echo "$ac_t""no" 1>&6
  751. fi
  752. if test -z "$CC"; then
  753. case "`uname -s`" in
  754. *win32* | *WIN32*)
  755. # Extract the first word of "cl", so it can be a program name with args.
  756. set dummy cl; ac_word=$2
  757. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  758. echo "configure:837: checking for $ac_word" >&5
  759. if test -n "$CC"; then
  760. ac_cv_prog_CC="$CC" # Let the user override the test.
  761. else
  762. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  763. ac_dummy="$PATH"
  764. for ac_dir in $ac_dummy; do
  765. test -z "$ac_dir" && ac_dir=.
  766. if test -f $ac_dir/$ac_word; then
  767. ac_cv_prog_CC="cl"
  768. break
  769. fi
  770. done
  771. IFS="$ac_save_ifs"
  772. fi
  773. CC="$ac_cv_prog_CC"
  774. if test -n "$CC"; then
  775. echo "$ac_t""$CC" 1>&6
  776. else
  777. echo "$ac_t""no" 1>&6
  778. fi
  779. ;;
  780. esac
  781. fi
  782. test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
  783. fi
  784. echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
  785. echo "configure:866: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
  786. ac_ext=c
  787. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  788. ac_cpp='$CPP $CPPFLAGS'
  789. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  790. ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  791. cross_compiling=$ac_cv_prog_cc_cross
  792. cat > conftest.$ac_ext << EOF
  793. #line 877 "configure"
  794. #include "confdefs.h"
  795. main(){return(0);}
  796. EOF
  797. if { (eval echo configure:882: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  798. ac_cv_prog_cc_works=yes
  799. # If we can't run a trivial program, we are probably using a cross compiler.
  800. if (./conftest; exit) 2>/dev/null; then
  801. ac_cv_prog_cc_cross=no
  802. else
  803. ac_cv_prog_cc_cross=yes
  804. fi
  805. else
  806. echo "configure: failed program was:" >&5
  807. cat conftest.$ac_ext >&5
  808. ac_cv_prog_cc_works=no
  809. fi
  810. rm -fr conftest*
  811. ac_ext=c
  812. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  813. ac_cpp='$CPP $CPPFLAGS'
  814. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  815. ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  816. cross_compiling=$ac_cv_prog_cc_cross
  817. echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
  818. if test $ac_cv_prog_cc_works = no; then
  819. { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
  820. fi
  821. echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
  822. echo "configure:908: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
  823. echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
  824. cross_compiling=$ac_cv_prog_cc_cross
  825. echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
  826. echo "configure:913: checking whether we are using GNU C" >&5
  827. cat > conftest.c <<EOF
  828. #ifdef __GNUC__
  829. yes;
  830. #endif
  831. EOF
  832. if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:920: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
  833. ac_cv_prog_gcc=yes
  834. else
  835. ac_cv_prog_gcc=no
  836. fi
  837. echo "$ac_t""$ac_cv_prog_gcc" 1>&6
  838. if test $ac_cv_prog_gcc = yes; then
  839. GCC=yes
  840. else
  841. GCC=
  842. fi
  843. ac_test_CFLAGS="${CFLAGS+set}"
  844. ac_save_CFLAGS="$CFLAGS"
  845. CFLAGS=
  846. echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
  847. echo "configure:938: checking whether ${CC-cc} accepts -g" >&5
  848. echo 'void f(){}' > conftest.c
  849. if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
  850. ac_cv_prog_cc_g=yes
  851. else
  852. ac_cv_prog_cc_g=no
  853. fi
  854. rm -f conftest*
  855. echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
  856. if test "$ac_test_CFLAGS" = set; then
  857. CFLAGS="$ac_save_CFLAGS"
  858. elif test $ac_cv_prog_cc_g = yes; then
  859. if test "$GCC" = yes; then
  860. CFLAGS="-g -O2"
  861. else
  862. CFLAGS="-g"
  863. fi
  864. else
  865. if test "$GCC" = yes; then
  866. CFLAGS="-O2"
  867. else
  868. CFLAGS=
  869. fi
  870. fi
  871. echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
  872. echo "configure:967: checking for Cygwin environment" >&5
  873. cat > conftest.$ac_ext <<EOF
  874. #line 970 "configure"
  875. #include "confdefs.h"
  876. int main() {
  877. #ifndef __CYGWIN__
  878. #define __CYGWIN__ __CYGWIN32__
  879. #endif
  880. return __CYGWIN__;
  881. ; return 0; }
  882. EOF
  883. if { (eval echo configure:981: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  884. rm -rf conftest*
  885. ac_cv_cygwin=yes
  886. else
  887. echo "configure: failed program was:" >&5
  888. cat conftest.$ac_ext >&5
  889. rm -rf conftest*
  890. ac_cv_cygwin=no
  891. fi
  892. rm -f conftest*
  893. rm -f conftest*
  894. echo "$ac_t""$ac_cv_cygwin" 1>&6
  895. CYGWIN=
  896. test "$ac_cv_cygwin" = yes && CYGWIN=yes
  897. echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
  898. echo "configure:997: checking for mingw32 environment" >&5
  899. cat > conftest.$ac_ext <<EOF
  900. #line 1000 "configure"
  901. #include "confdefs.h"
  902. int main() {
  903. return __MINGW32__;
  904. ; return 0; }
  905. EOF
  906. if { (eval echo configure:1007: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  907. rm -rf conftest*
  908. ac_cv_mingw32=yes
  909. else
  910. echo "configure: failed program was:" >&5
  911. cat conftest.$ac_ext >&5
  912. rm -rf conftest*
  913. ac_cv_mingw32=no
  914. fi
  915. rm -f conftest*
  916. rm -f conftest*
  917. echo "$ac_t""$ac_cv_mingw32" 1>&6
  918. MINGW32=
  919. test "$ac_cv_mingw32" = yes && MINGW32=yes
  920. echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
  921. echo "configure:1025: checking for executable suffix" >&5
  922. if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
  923. ac_cv_exeext=.exe
  924. else
  925. ac_cv_exeext=no
  926. fi
  927. EXEEXT=""
  928. test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
  929. echo "$ac_t""${ac_cv_exeext}" 1>&6
  930. ac_exeext=$EXEEXT
  931. # Check for full floating-point support, including Infinity and NaN
  932. IEEEFLAG=
  933. echo $ac_n "checking for full floating-point support""... $ac_c" 1>&6
  934. echo "configure:1044: checking for full floating-point support" >&5
  935. if test "$cross_compiling" = yes; then
  936. echo "$ac_t""unknown (cross-compiling)" 1>&6
  937. echo $ac_n "checking whether "cc -mieee" works""... $ac_c" 1>&6
  938. echo "configure:1049: checking whether "cc -mieee" works" >&5
  939. ac_save_cflags=${CFLAGS}
  940. CFLAGS="$CFLAGS -mieee"
  941. cat > conftest.$ac_ext <<EOF
  942. #line 1053 "configure"
  943. #include "confdefs.h"
  944. int main() {
  945. ; return 0; }
  946. EOF
  947. if { (eval echo configure:1060: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  948. rm -rf conftest*
  949. echo "$ac_t""yes" 1>&6
  950. IEEEFLAG="-mieee"
  951. else
  952. echo "configure: failed program was:" >&5
  953. cat conftest.$ac_ext >&5
  954. rm -rf conftest*
  955. echo "$ac_t""no" 1>&6
  956. fi
  957. rm -f conftest*
  958. CFLAGS=${ac_save_cflags}
  959. else
  960. cat > conftest.$ac_ext <<EOF
  961. #line 1076 "configure"
  962. #include "confdefs.h"
  963. #include <float.h>
  964. int main(void) {
  965. double one = 1.0;
  966. double zero = 0.0;
  967. if (one/zero > DBL_MAX) /* infinity */
  968. if (zero/zero != zero/zero) /* NaN */
  969. return 0;
  970. return 1;
  971. }
  972. EOF
  973. if { (eval echo configure:1090: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  974. then
  975. echo "$ac_t""yes" 1>&6
  976. else
  977. echo "configure: failed program was:" >&5
  978. cat conftest.$ac_ext >&5
  979. rm -fr conftest*
  980. echo "$ac_t""no" 1>&6
  981. ac_save_cflags=${CFLAGS}
  982. CFLAGS=-mieee
  983. echo $ac_n "checking for full floating-point support with -mieee""... $ac_c" 1>&6
  984. echo "configure:1103: checking for full floating-point support with -mieee" >&5
  985. if test "$cross_compiling" = yes; then
  986. echo "$ac_t""unknown (cross-compiling)" 1>&6
  987. { echo "configure: error: *** INTERNAL CONFIGURE ERROR" 1>&2; exit 1; }
  988. else
  989. cat > conftest.$ac_ext <<EOF
  990. #line 1110 "configure"
  991. #include "confdefs.h"
  992. #include <float.h>
  993. int main(void) {
  994. double one = 1.0;
  995. double zero = 0.0;
  996. if (one/zero > DBL_MAX) /* infinity */
  997. if (zero/zero != zero/zero) /* NaN */
  998. return 0;
  999. return 1;
  1000. }
  1001. EOF
  1002. if { (eval echo configure:1124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  1003. then
  1004. echo "$ac_t""yes" 1>&6
  1005. IEEEFLAG="-mieee"
  1006. else
  1007. echo "configure: failed program was:" >&5
  1008. cat conftest.$ac_ext >&5
  1009. rm -fr conftest*
  1010. echo "$ac_t""no" 1>&6
  1011. echo "configure: warning: *** Incomplete floating-point support." 1>&2
  1012. fi
  1013. rm -fr conftest*
  1014. fi
  1015. CFLAGS=${ac_save_cflags}
  1016. fi
  1017. rm -fr conftest*
  1018. fi
  1019. CFLAGS="$CFLAGS $IEEEFLAG"
  1020. # Set BINDIR
  1021. if test -n "${bindir}"; then
  1022. BINDIR="${bindir}"
  1023. else
  1024. BINDIR=/usr/local/bin
  1025. fi
  1026. # Set SRCDIR and DSTDIR
  1027. # Extract the first word of "pwd", so it can be a program name with args.
  1028. set dummy pwd; ac_word=$2
  1029. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  1030. echo "configure:1161: checking for $ac_word" >&5
  1031. case "$pwd" in
  1032. /*)
  1033. ac_cv_path_pwd="$pwd" # Let the user override the test with a path.
  1034. ;;
  1035. ?:/*)
  1036. ac_cv_path_pwd="$pwd" # Let the user override the test with a dos path.
  1037. ;;
  1038. *)
  1039. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  1040. ac_dummy="$PATH"
  1041. for ac_dir in $ac_dummy; do
  1042. test -z "$ac_dir" && ac_dir=.
  1043. if test -f $ac_dir/$ac_word; then
  1044. ac_cv_path_pwd="$ac_dir/$ac_word"
  1045. break
  1046. fi
  1047. done
  1048. IFS="$ac_save_ifs"
  1049. test -z "$ac_cv_path_pwd" && ac_cv_path_pwd="pwd"
  1050. ;;
  1051. esac
  1052. pwd="$ac_cv_path_pwd"
  1053. if test -n "$pwd"; then
  1054. echo "$ac_t""$pwd" 1>&6
  1055. else
  1056. echo "$ac_t""no" 1>&6
  1057. fi
  1058. if test "$MINGW32" = yes ; then
  1059. winpwd="$pwd -W"
  1060. else
  1061. winpwd="$pwd"
  1062. fi
  1063. echo $ac_n "checking for source directory""... $ac_c" 1>&6
  1064. echo "configure:1199: checking for source directory" >&5
  1065. if test -z "$srcdir" ; then
  1066. SRCDIR=`$pwd`
  1067. else
  1068. SRCDIR=`(cd "$srcdir" ; $pwd)`
  1069. fi
  1070. echo "$ac_t"""$SRCDIR"" 1>&6
  1071. echo $ac_n "checking for build directory""... $ac_c" 1>&6
  1072. echo "configure:1210: checking for build directory" >&5
  1073. DSTDIR=`$pwd`
  1074. WINDSTDIR=`$winpwd`
  1075. echo "$ac_t"""$DSTDIR"" 1>&6
  1076. # Set ARCH
  1077. ARCH=
  1078. if test -z "${host}"; then
  1079. ARCH="unknown"
  1080. else
  1081. ARCH="${host}"
  1082. fi
  1083. # Use absolute path for aux directory so that install-sh works
  1084. ac_aux_dir=
  1085. for ac_dir in $SRCDIR $srcdir/$SRCDIR; do
  1086. if test -f $ac_dir/install-sh; then
  1087. ac_aux_dir=$ac_dir
  1088. ac_install_sh="$ac_aux_dir/install-sh -c"
  1089. break
  1090. elif test -f $ac_dir/install.sh; then
  1091. ac_aux_dir=$ac_dir
  1092. ac_install_sh="$ac_aux_dir/install.sh -c"
  1093. break
  1094. fi
  1095. done
  1096. if test -z "$ac_aux_dir"; then
  1097. { echo "configure: error: can not find install-sh or install.sh in $SRCDIR $srcdir/$SRCDIR" 1>&2; exit 1; }
  1098. fi
  1099. ac_config_guess=$ac_aux_dir/config.guess
  1100. ac_config_sub=$ac_aux_dir/config.sub
  1101. ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
  1102. # Set GISBASE and GRASS_BIN
  1103. GISBASE=${WINDSTDIR}/dist.${ARCH}
  1104. GRASS_BIN=${DSTDIR}/bin.${ARCH}
  1105. # Set GRASS_VERSION_*
  1106. GRASS_VERSION_FILE=include/VERSION
  1107. GRASS_VERSION_MAJOR=`sed -n 1p ${GRASS_VERSION_FILE}`
  1108. GRASS_VERSION_MINOR=`sed -n 2p ${GRASS_VERSION_FILE}`
  1109. GRASS_VERSION_RELEASE=`sed -n 3p ${GRASS_VERSION_FILE}`
  1110. GRASS_VERSION_DATE=`sed -n 4p ${GRASS_VERSION_FILE}`
  1111. GRASS_VERSION_NUMBER=`echo ${GRASS_VERSION_MAJOR}.${GRASS_VERSION_MINOR}.${GRASS_VERSION_RELEASE}`
  1112. NAME_VER=`echo ${GRASS_VERSION_NUMBER} | sed 's/\..*//'`
  1113. LIB_VER=`echo ${GRASS_VERSION_NUMBER} | sed 's/^\([0-9.]*\).*$/\1/'`
  1114. # Check for MacOSX App
  1115. # Check whether --enable-macosx-app or --disable-macosx-app was given.
  1116. if test "${enable_macosx_app+set}" = set; then
  1117. enableval="$enable_macosx_app"
  1118. :
  1119. else
  1120. enable_macosx_app=no
  1121. fi
  1122. echo $ac_n "checking for MacOSX App""... $ac_c" 1>&6
  1123. echo "configure:1295: checking for MacOSX App" >&5
  1124. case "$enable_macosx_app" in
  1125. yes) MACOSX_APP=1 ;;
  1126. no) MACOSX_APP= ;;
  1127. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  1128. esac
  1129. echo "$ac_t"""$enable_macosx_app"" 1>&6
  1130. # Set INST_DIR
  1131. if test -n "$MACOSX_APP" ; then
  1132. INSTDIR='${prefix}'"/GRASS-${GRASS_VERSION_MAJOR}.${GRASS_VERSION_MINOR}.app/Contents/MacOS"
  1133. else
  1134. INSTDIR='${prefix}'"/grass-${GRASS_VERSION_MAJOR}.${GRASS_VERSION_MINOR}.${GRASS_VERSION_RELEASE}"
  1135. fi
  1136. # Get flags for building shared libraries
  1137. echo $ac_n "checking how to build libraries""... $ac_c" 1>&6
  1138. echo "configure:1318: checking how to build libraries" >&5
  1139. # Check whether --enable-shared or --disable-shared was given.
  1140. if test "${enable_shared+set}" = set; then
  1141. enableval="$enable_shared"
  1142. shared_ok=$enableval
  1143. else
  1144. shared_ok=yes
  1145. fi
  1146. if test "${enable_shared+set}" = set; then
  1147. enableval="$enable_shared"
  1148. shared_ok=$enableval
  1149. else
  1150. shared_ok=yes
  1151. fi
  1152. if test "$shared_ok" = "yes" ; then
  1153. echo "$ac_t""shared" 1>&6
  1154. SHARED_BUILD=1
  1155. GRASS_LIB_PREFIX='$(SHLIB_PREFIX)'
  1156. GRASS_LIB_SUFFIX='$(SHLIB_SUFFIX)'
  1157. GRASS_LIBRARY_TYPE='shlib'
  1158. else
  1159. echo "$ac_t""static" 1>&6
  1160. SHARED_BUILD=0
  1161. cat >> confdefs.h <<\EOF
  1162. #define STATIC_BUILD 1
  1163. EOF
  1164. GRASS_LIB_PREFIX='$(STLIB_PREFIX)'
  1165. GRASS_LIB_SUFFIX='$(STLIB_SUFFIX)'
  1166. GRASS_LIBRARY_TYPE='stlib'
  1167. fi
  1168. ac_save_ldflags="$LDFLAGS"
  1169. # Extract the first word of "ranlib", so it can be a program name with args.
  1170. set dummy ranlib; ac_word=$2
  1171. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  1172. echo "configure:1361: checking for $ac_word" >&5
  1173. if test -n "$RANLIB"; then
  1174. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  1175. else
  1176. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  1177. ac_dummy="$PATH"
  1178. for ac_dir in $ac_dummy; do
  1179. test -z "$ac_dir" && ac_dir=.
  1180. if test -f $ac_dir/$ac_word; then
  1181. ac_cv_prog_RANLIB="ranlib"
  1182. break
  1183. fi
  1184. done
  1185. IFS="$ac_save_ifs"
  1186. test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
  1187. fi
  1188. RANLIB="$ac_cv_prog_RANLIB"
  1189. if test -n "$RANLIB"; then
  1190. echo "$ac_t""$RANLIB" 1>&6
  1191. else
  1192. echo "$ac_t""no" 1>&6
  1193. fi
  1194. echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
  1195. echo "configure:1386: checking how to run the C preprocessor" >&5
  1196. # On Suns, sometimes $CPP names a directory.
  1197. if test -n "$CPP" && test -d "$CPP"; then
  1198. CPP=
  1199. fi
  1200. if test -z "$CPP"; then
  1201. # This must be in double quotes, not single quotes, because CPP may get
  1202. # substituted into the Makefile and "${CC-cc}" will confuse make.
  1203. CPP="${CC-cc} -E"
  1204. # On the NeXT, cc -E runs the code through the compiler's parser,
  1205. # not just through cpp.
  1206. cat > conftest.$ac_ext <<EOF
  1207. #line 1399 "configure"
  1208. #include "confdefs.h"
  1209. #include <assert.h>
  1210. Syntax Error
  1211. EOF
  1212. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1213. { (eval echo configure:1405: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  1214. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  1215. if test -z "$ac_err"; then
  1216. :
  1217. else
  1218. echo "$ac_err" >&5
  1219. echo "configure: failed program was:" >&5
  1220. cat conftest.$ac_ext >&5
  1221. rm -rf conftest*
  1222. CPP="${CC-cc} -E -traditional-cpp"
  1223. cat > conftest.$ac_ext <<EOF
  1224. #line 1416 "configure"
  1225. #include "confdefs.h"
  1226. #include <assert.h>
  1227. Syntax Error
  1228. EOF
  1229. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1230. { (eval echo configure:1422: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  1231. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  1232. if test -z "$ac_err"; then
  1233. :
  1234. else
  1235. echo "$ac_err" >&5
  1236. echo "configure: failed program was:" >&5
  1237. cat conftest.$ac_ext >&5
  1238. rm -rf conftest*
  1239. CPP="${CC-cc} -nologo -E"
  1240. cat > conftest.$ac_ext <<EOF
  1241. #line 1433 "configure"
  1242. #include "confdefs.h"
  1243. #include <assert.h>
  1244. Syntax Error
  1245. EOF
  1246. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1247. { (eval echo configure:1439: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  1248. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  1249. if test -z "$ac_err"; then
  1250. :
  1251. else
  1252. echo "$ac_err" >&5
  1253. echo "configure: failed program was:" >&5
  1254. cat conftest.$ac_ext >&5
  1255. rm -rf conftest*
  1256. CPP=/lib/cpp
  1257. fi
  1258. rm -f conftest*
  1259. fi
  1260. rm -f conftest*
  1261. fi
  1262. rm -f conftest*
  1263. ac_cv_prog_CPP="$CPP"
  1264. CPP="$ac_cv_prog_CPP"
  1265. else
  1266. ac_cv_prog_CPP="$CPP"
  1267. fi
  1268. echo "$ac_t""$CPP" 1>&6
  1269. # Step 0.a: Enable 64 bit support?
  1270. echo $ac_n "checking if 64bit support is requested""... $ac_c" 1>&6
  1271. echo "configure:1467: checking if 64bit support is requested" >&5
  1272. # Check whether --enable-64bit or --disable-64bit was given.
  1273. if test "${enable_64bit+set}" = set; then
  1274. enableval="$enable_64bit"
  1275. :
  1276. else
  1277. enableval="no"
  1278. fi
  1279. if test "$enableval" = "yes"; then
  1280. do64bit=yes
  1281. else
  1282. do64bit=no
  1283. fi
  1284. echo "$ac_t""$do64bit" 1>&6
  1285. # Step 0.b: Enable Solaris 64 bit VIS support?
  1286. echo $ac_n "checking if 64bit Sparc VIS support is requested""... $ac_c" 1>&6
  1287. echo "configure:1487: checking if 64bit Sparc VIS support is requested" >&5
  1288. # Check whether --enable-64bit-vis or --disable-64bit-vis was given.
  1289. if test "${enable_64bit_vis+set}" = set; then
  1290. enableval="$enable_64bit_vis"
  1291. :
  1292. else
  1293. enableval="no"
  1294. fi
  1295. if test "$enableval" = "yes"; then
  1296. # Force 64bit on with VIS
  1297. do64bit=yes
  1298. do64bitVIS=yes
  1299. else
  1300. do64bitVIS=no
  1301. fi
  1302. echo "$ac_t""$do64bitVIS" 1>&6
  1303. # Step 1: set the variable "system" to hold the name and version number
  1304. # for the system. This can usually be done via the "uname" command, but
  1305. # there are a few systems, like Next, where this doesn't work.
  1306. echo $ac_n "checking system version (for dynamic loading)""... $ac_c" 1>&6
  1307. echo "configure:1511: checking system version (for dynamic loading)" >&5
  1308. if test -f /usr/lib/NextStep/software_version; then
  1309. system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version`
  1310. else
  1311. system=`uname -s`-`uname -r`
  1312. if test "$?" -ne 0 ; then
  1313. echo "$ac_t""unknown (can't find uname command)" 1>&6
  1314. system=unknown
  1315. else
  1316. # Special check for weird MP-RAS system (uname returns weird
  1317. # results, and the version is kept in special file).
  1318. if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then
  1319. system=MP-RAS-`awk '{print }' /etc/.relid`
  1320. fi
  1321. if test "`uname -s`" = "AIX" ; then
  1322. system=AIX-`uname -v`.`uname -r`
  1323. fi
  1324. echo "$ac_t""$system" 1>&6
  1325. fi
  1326. fi
  1327. # Step 2: check for existence of -ldl library. This is needed because
  1328. # Linux can use either -ldl or -ldld for dynamic loading.
  1329. echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
  1330. echo "configure:1537: checking for dlopen in -ldl" >&5
  1331. ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
  1332. ac_save_LIBS="$LIBS"
  1333. LIBS="-ldl $LIBS"
  1334. cat > conftest.$ac_ext <<EOF
  1335. #line 1543 "configure"
  1336. #include "confdefs.h"
  1337. /* Override any gcc2 internal prototype to avoid an error. */
  1338. /* We use char because int might match the return type of a gcc2
  1339. builtin and then its argument prototype would still apply. */
  1340. char dlopen();
  1341. int main() {
  1342. dlopen()
  1343. ; return 0; }
  1344. EOF
  1345. if { (eval echo configure:1554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  1346. rm -rf conftest*
  1347. eval "ac_cv_lib_$ac_lib_var=yes"
  1348. else
  1349. echo "configure: failed program was:" >&5
  1350. cat conftest.$ac_ext >&5
  1351. rm -rf conftest*
  1352. eval "ac_cv_lib_$ac_lib_var=no"
  1353. fi
  1354. rm -f conftest*
  1355. LIBS="$ac_save_LIBS"
  1356. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  1357. echo "$ac_t""yes" 1>&6
  1358. have_dl=yes
  1359. else
  1360. echo "$ac_t""no" 1>&6
  1361. have_dl=no
  1362. fi
  1363. # Require ranlib early so we can override it in special cases below.
  1364. # Step 3: set configuration options based on system name and version.
  1365. do64bit_ok=no
  1366. EXTRA_CFLAGS=""
  1367. GRASS_EXPORT_FILE_SUFFIX=""
  1368. UNSHARED_LIB_SUFFIX=""
  1369. GRASS_TRIM_DOTS='`echo ${LIB_VER} | tr -d .`'
  1370. ECHO_VERSION='`echo ${LIB_VER}`'
  1371. GRASS_LIB_VERSIONS_OK=ok
  1372. CFLAGS_DEBUG=-g
  1373. CFLAGS_OPTIMIZE=-O
  1374. if test "$GCC" = "yes" ; then
  1375. CFLAGS_WARNING="-Wall -Wconversion -Wno-implicit-int"
  1376. else
  1377. CFLAGS_WARNING=""
  1378. fi
  1379. GRASS_NEEDS_EXP_FILE=0
  1380. GRASS_BUILD_EXP_FILE=""
  1381. GRASS_EXP_FILE=""
  1382. # Extract the first word of "ar", so it can be a program name with args.
  1383. set dummy ar; ac_word=$2
  1384. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  1385. echo "configure:1601: checking for $ac_word" >&5
  1386. if test -n "$AR"; then
  1387. ac_cv_prog_AR="$AR" # Let the user override the test.
  1388. else
  1389. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  1390. ac_dummy="$PATH"
  1391. for ac_dir in $ac_dummy; do
  1392. test -z "$ac_dir" && ac_dir=.
  1393. if test -f $ac_dir/$ac_word; then
  1394. ac_cv_prog_AR="ar"
  1395. break
  1396. fi
  1397. done
  1398. IFS="$ac_save_ifs"
  1399. fi
  1400. AR="$ac_cv_prog_AR"
  1401. if test -n "$AR"; then
  1402. echo "$ac_t""$AR" 1>&6
  1403. else
  1404. echo "$ac_t""no" 1>&6
  1405. fi
  1406. if test "${AR}" = "" ; then
  1407. { echo "configure: error: Required archive tool 'ar' not found on PATH." 1>&2; exit 1; }
  1408. fi
  1409. STLIB_LD='${AR} cr'
  1410. LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH"
  1411. PLAT_OBJS=""
  1412. case $system in
  1413. AIX-5.*)
  1414. if test "${GRASS_THREADS}" = "1" -a "$GCC" != "yes" ; then
  1415. # AIX requires the _r compiler when gcc isn't being used
  1416. if test "${CC}" != "cc_r" ; then
  1417. CC=${CC}_r
  1418. fi
  1419. echo "$ac_t""Using $CC for compiling with threads" 1>&6
  1420. fi
  1421. LIBS="$LIBS -lc"
  1422. # AIX-5 uses ELF style dynamic libraries
  1423. SHLIB_CFLAGS=""
  1424. # Note: need the LIBS below, otherwise Tk won't find Tcl's
  1425. # symbols when dynamically loaded into tclsh.
  1426. SHLIB_LD_LIBS='${LIBS}'
  1427. SHLIB_SUFFIX=".so"
  1428. LDFLAGS=""
  1429. LD_LIBRARY_PATH_VAR="LIBPATH"
  1430. # Check to enable 64-bit flags for compiler/linker
  1431. if test "$do64bit" = "yes" ; then
  1432. if test "$GCC" = "yes" ; then
  1433. echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
  1434. else
  1435. do64bit_ok=yes
  1436. EXTRA_CFLAGS="-q64"
  1437. LDFLAGS="-q64"
  1438. RANLIB="${RANLIB} -X64"
  1439. AR="${AR} -X64"
  1440. SHLIB_LD_FLAGS="-b64"
  1441. fi
  1442. fi
  1443. if test "`uname -m`" = "ia64" ; then
  1444. # AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC
  1445. SHLIB_LD="/usr/ccs/bin/ld -G -z text"
  1446. # AIX-5 has dl* in libc.so
  1447. if test "$GCC" = "yes" ; then
  1448. CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
  1449. else
  1450. CC_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
  1451. fi
  1452. LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
  1453. else
  1454. SHLIB_LD="${SRCDIR}/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry ${SHLIB_LD_FLAGS}"
  1455. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  1456. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  1457. GRASS_NEEDS_EXP_FILE=1
  1458. GRASS_EXPORT_FILE_SUFFIX='${LIB_VER}.exp'
  1459. fi
  1460. ;;
  1461. AIX-*)
  1462. if test "${GRASS_THREADS}" = "1" -a "$GCC" != "yes" ; then
  1463. # AIX requires the _r compiler when gcc isn't being used
  1464. if test "${CC}" != "cc_r" ; then
  1465. CC=${CC}_r
  1466. fi
  1467. echo "$ac_t""Using $CC for compiling with threads" 1>&6
  1468. fi
  1469. LIBS="$LIBS -lc"
  1470. SHLIB_CFLAGS=""
  1471. SHLIB_LD_LIBS='${LIBS}'
  1472. SHLIB_SUFFIX=".so"
  1473. LDFLAGS=""
  1474. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  1475. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  1476. LD_LIBRARY_PATH_VAR="LIBPATH"
  1477. GRASS_NEEDS_EXP_FILE=1
  1478. GRASS_EXPORT_FILE_SUFFIX='${LIB_VER}.exp'
  1479. # Check to enable 64-bit flags for compiler/linker
  1480. if test "$do64bit" = "yes" ; then
  1481. if test "$GCC" = "yes" ; then
  1482. echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
  1483. else
  1484. do64bit_ok=yes
  1485. EXTRA_CFLAGS="-q64"
  1486. LDFLAGS="-q64"
  1487. RANLIB="${RANLIB} -X64"
  1488. AR="${AR} -X64"
  1489. SHLIB_LD_FLAGS="-b64"
  1490. fi
  1491. fi
  1492. SHLIB_LD="${SRCDIR}/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry ${SHLIB_LD_FLAGS}"
  1493. # On AIX <=v4 systems, libbsd.a has to be linked in to support
  1494. # non-blocking file IO. This library has to be linked in after
  1495. # the MATH_LIBS or it breaks the pow() function. The way to
  1496. # insure proper sequencing, is to add it to the tail of MATH_LIBS.
  1497. # This library also supplies gettimeofday.
  1498. #
  1499. # AIX does not have a timezone field in struct tm. When the AIX
  1500. # bsd library is used, the timezone global and the gettimeofday
  1501. # methods are to be avoided for timezone deduction instead, we
  1502. # deduce the timezone by comparing the localtime result on a
  1503. # known GMT value.
  1504. echo $ac_n "checking for gettimeofday in -lbsd""... $ac_c" 1>&6
  1505. echo "configure:1730: checking for gettimeofday in -lbsd" >&5
  1506. ac_lib_var=`echo bsd'_'gettimeofday | sed 'y%./+-%__p_%'`
  1507. ac_save_LIBS="$LIBS"
  1508. LIBS="-lbsd $LIBS"
  1509. cat > conftest.$ac_ext <<EOF
  1510. #line 1736 "configure"
  1511. #include "confdefs.h"
  1512. /* Override any gcc2 internal prototype to avoid an error. */
  1513. /* We use char because int might match the return type of a gcc2
  1514. builtin and then its argument prototype would still apply. */
  1515. char gettimeofday();
  1516. int main() {
  1517. gettimeofday()
  1518. ; return 0; }
  1519. EOF
  1520. if { (eval echo configure:1747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  1521. rm -rf conftest*
  1522. eval "ac_cv_lib_$ac_lib_var=yes"
  1523. else
  1524. echo "configure: failed program was:" >&5
  1525. cat conftest.$ac_ext >&5
  1526. rm -rf conftest*
  1527. eval "ac_cv_lib_$ac_lib_var=no"
  1528. fi
  1529. rm -f conftest*
  1530. LIBS="$ac_save_LIBS"
  1531. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  1532. echo "$ac_t""yes" 1>&6
  1533. libbsd=yes
  1534. else
  1535. echo "$ac_t""no" 1>&6
  1536. libbsd=no
  1537. fi
  1538. if test $libbsd = yes; then
  1539. MATH_LIBS="$MATH_LIBS -lbsd"
  1540. cat >> confdefs.h <<\EOF
  1541. #define USE_DELTA_FOR_TZ 1
  1542. EOF
  1543. fi
  1544. ;;
  1545. BeOS*)
  1546. SHLIB_CFLAGS="-fPIC"
  1547. SHLIB_LD="${CC} -nostart"
  1548. SHLIB_LD_LIBS='${LIBS}'
  1549. SHLIB_SUFFIX=".so"
  1550. LDFLAGS=""
  1551. #-----------------------------------------------------------
  1552. # Check for inet_ntoa in -lbind, for BeOS (which also needs
  1553. # -lsocket, even if the network functions are in -lnet which
  1554. # is always linked to, for compatibility.
  1555. #-----------------------------------------------------------
  1556. echo $ac_n "checking for inet_ntoa in -lbind""... $ac_c" 1>&6
  1557. echo "configure:1788: checking for inet_ntoa in -lbind" >&5
  1558. ac_lib_var=`echo bind'_'inet_ntoa | sed 'y%./+-%__p_%'`
  1559. ac_save_LIBS="$LIBS"
  1560. LIBS="-lbind $LIBS"
  1561. cat > conftest.$ac_ext <<EOF
  1562. #line 1794 "configure"
  1563. #include "confdefs.h"
  1564. /* Override any gcc2 internal prototype to avoid an error. */
  1565. /* We use char because int might match the return type of a gcc2
  1566. builtin and then its argument prototype would still apply. */
  1567. char inet_ntoa();
  1568. int main() {
  1569. inet_ntoa()
  1570. ; return 0; }
  1571. EOF
  1572. if { (eval echo configure:1805: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  1573. rm -rf conftest*
  1574. eval "ac_cv_lib_$ac_lib_var=yes"
  1575. else
  1576. echo "configure: failed program was:" >&5
  1577. cat conftest.$ac_ext >&5
  1578. rm -rf conftest*
  1579. eval "ac_cv_lib_$ac_lib_var=no"
  1580. fi
  1581. rm -f conftest*
  1582. LIBS="$ac_save_LIBS"
  1583. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  1584. echo "$ac_t""yes" 1>&6
  1585. LIBS="$LIBS -lbind -lsocket"
  1586. else
  1587. echo "$ac_t""no" 1>&6
  1588. fi
  1589. ;;
  1590. BSD/OS-2.1*|BSD/OS-3*)
  1591. SHLIB_CFLAGS=""
  1592. SHLIB_LD="shlicc -r"
  1593. SHLIB_LD_LIBS='${LIBS}'
  1594. SHLIB_SUFFIX=".so"
  1595. LDFLAGS=""
  1596. CC_SEARCH_FLAGS=""
  1597. LD_SEARCH_FLAGS=""
  1598. ;;
  1599. BSD/OS-4.*)
  1600. SHLIB_CFLAGS="-export-dynamic -fPIC"
  1601. SHLIB_LD="cc -shared"
  1602. SHLIB_LD_LIBS='${LIBS}'
  1603. SHLIB_SUFFIX=".so"
  1604. LDFLAGS="-export-dynamic"
  1605. CC_SEARCH_FLAGS=""
  1606. LD_SEARCH_FLAGS=""
  1607. ;;
  1608. dgux*)
  1609. SHLIB_CFLAGS="-K PIC"
  1610. SHLIB_LD="cc -G"
  1611. SHLIB_LD_LIBS=""
  1612. SHLIB_SUFFIX=".so"
  1613. LDFLAGS=""
  1614. CC_SEARCH_FLAGS=""
  1615. LD_SEARCH_FLAGS=""
  1616. ;;
  1617. HP-UX-*.11.*)
  1618. # Use updated header definitions where possible
  1619. cat >> confdefs.h <<\EOF
  1620. #define _XOPEN_SOURCE 1
  1621. EOF
  1622. # Use the XOPEN network library
  1623. cat >> confdefs.h <<\EOF
  1624. #define _XOPEN_SOURCE_EXTENDED 1
  1625. EOF
  1626. # Use the XOPEN network library
  1627. LIBS="$LIBS -lxnet" # Use the XOPEN network library
  1628. SHLIB_SUFFIX=".sl"
  1629. echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
  1630. echo "configure:1866: checking for shl_load in -ldld" >&5
  1631. ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
  1632. ac_save_LIBS="$LIBS"
  1633. LIBS="-ldld $LIBS"
  1634. cat > conftest.$ac_ext <<EOF
  1635. #line 1872 "configure"
  1636. #include "confdefs.h"
  1637. /* Override any gcc2 internal prototype to avoid an error. */
  1638. /* We use char because int might match the return type of a gcc2
  1639. builtin and then its argument prototype would still apply. */
  1640. char shl_load();
  1641. int main() {
  1642. shl_load()
  1643. ; return 0; }
  1644. EOF
  1645. if { (eval echo configure:1883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  1646. rm -rf conftest*
  1647. eval "ac_cv_lib_$ac_lib_var=yes"
  1648. else
  1649. echo "configure: failed program was:" >&5
  1650. cat conftest.$ac_ext >&5
  1651. rm -rf conftest*
  1652. eval "ac_cv_lib_$ac_lib_var=no"
  1653. fi
  1654. rm -f conftest*
  1655. LIBS="$ac_save_LIBS"
  1656. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  1657. echo "$ac_t""yes" 1>&6
  1658. shared_ok=yes
  1659. else
  1660. echo "$ac_t""no" 1>&6
  1661. shared_ok=no
  1662. fi
  1663. if test "$shared_ok" = yes; then
  1664. SHLIB_CFLAGS="+z"
  1665. SHLIB_LD="ld -b"
  1666. SHLIB_LD_LIBS='${LIBS}'
  1667. LDFLAGS="-Wl,-E"
  1668. CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
  1669. LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
  1670. LD_LIBRARY_PATH_VAR="SHLIB_PATH"
  1671. fi
  1672. # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc
  1673. #EXTRA_CFLAGS="+DAportable"
  1674. # Check to enable 64-bit flags for compiler/linker
  1675. if test "$do64bit" = "yes" ; then
  1676. if test "$GCC" = "yes" ; then
  1677. hpux_arch=`gcc -dumpmachine`
  1678. case $hpux_arch in
  1679. hppa64*)
  1680. # 64-bit gcc in use. Fix flags for GNU ld.
  1681. do64bit_ok=yes
  1682. SHLIB_LD="gcc -shared"
  1683. SHLIB_LD_LIBS=""
  1684. LD_SEARCH_FLAGS=''
  1685. CC_SEARCH_FLAGS=''
  1686. ;;
  1687. *)
  1688. echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
  1689. ;;
  1690. esac
  1691. else
  1692. do64bit_ok=yes
  1693. if test "`uname -m`" = "ia64" ; then
  1694. EXTRA_CFLAGS="+DD64"
  1695. LDFLAGS="+DD64 $LDFLAGS"
  1696. else
  1697. EXTRA_CFLAGS="+DA2.0W"
  1698. LDFLAGS="+DA2.0W $LDFLAGS"
  1699. fi
  1700. fi
  1701. fi
  1702. ;;
  1703. HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*)
  1704. SHLIB_SUFFIX=".sl"
  1705. echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
  1706. echo "configure:1948: checking for shl_load in -ldld" >&5
  1707. ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
  1708. ac_save_LIBS="$LIBS"
  1709. LIBS="-ldld $LIBS"
  1710. cat > conftest.$ac_ext <<EOF
  1711. #line 1954 "configure"
  1712. #include "confdefs.h"
  1713. /* Override any gcc2 internal prototype to avoid an error. */
  1714. /* We use char because int might match the return type of a gcc2
  1715. builtin and then its argument prototype would still apply. */
  1716. char shl_load();
  1717. int main() {
  1718. shl_load()
  1719. ; return 0; }
  1720. EOF
  1721. if { (eval echo configure:1965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  1722. rm -rf conftest*
  1723. eval "ac_cv_lib_$ac_lib_var=yes"
  1724. else
  1725. echo "configure: failed program was:" >&5
  1726. cat conftest.$ac_ext >&5
  1727. rm -rf conftest*
  1728. eval "ac_cv_lib_$ac_lib_var=no"
  1729. fi
  1730. rm -f conftest*
  1731. LIBS="$ac_save_LIBS"
  1732. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  1733. echo "$ac_t""yes" 1>&6
  1734. shared_ok=yes
  1735. else
  1736. echo "$ac_t""no" 1>&6
  1737. shared_ok=no
  1738. fi
  1739. if test "$shared_ok" = yes; then
  1740. SHLIB_CFLAGS="+z"
  1741. SHLIB_LD="ld -b"
  1742. SHLIB_LD_LIBS=""
  1743. LDFLAGS="-Wl,-E"
  1744. CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.'
  1745. LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.'
  1746. LD_LIBRARY_PATH_VAR="SHLIB_PATH"
  1747. fi
  1748. ;;
  1749. IRIX-4.*)
  1750. SHLIB_CFLAGS="-G 0"
  1751. SHLIB_SUFFIX=".a"
  1752. SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
  1753. SHLIB_LD_LIBS='${LIBS}'
  1754. LDFLAGS="-Wl,-D,08000000"
  1755. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  1756. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  1757. SHARED_LIB_SUFFIX='${LIB_VER}.a'
  1758. ;;
  1759. IRIX-5.*)
  1760. SHLIB_CFLAGS=""
  1761. SHLIB_LD="ld -shared -rdata_shared"
  1762. SHLIB_LD_LIBS='${LIBS}'
  1763. SHLIB_SUFFIX=".so"
  1764. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  1765. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  1766. EXTRA_CFLAGS=""
  1767. LDFLAGS=""
  1768. ;;
  1769. IRIX-6.2)
  1770. SHLIB_CFLAGS=""
  1771. SHLIB_LD="ld -shared -rdata_shared"
  1772. SHLIB_LD_LIBS='${LIBS}'
  1773. SHLIB_SUFFIX=".so"
  1774. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  1775. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  1776. ;;
  1777. IRIX-6.*|IRIX64-6.5*)
  1778. SHLIB_CFLAGS=""
  1779. SHLIB_LD="ld -n32 -shared -rdata_shared"
  1780. SHLIB_LD_LIBS='${LIBS}'
  1781. SHLIB_SUFFIX=".so"
  1782. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  1783. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  1784. if test "$GCC" = "yes" ; then
  1785. EXTRA_CFLAGS="-mabi=n32"
  1786. LDFLAGS="-mabi=n32"
  1787. else
  1788. case $system in
  1789. IRIX-6.3)
  1790. # Use to build 6.2 compatible binaries on 6.3.
  1791. EXTRA_CFLAGS="-n32 -D_OLD_TERMIOS"
  1792. ;;
  1793. *)
  1794. EXTRA_CFLAGS="-n32"
  1795. ;;
  1796. esac
  1797. LDFLAGS="-n32"
  1798. fi
  1799. ;;
  1800. IRIX64-6.*)
  1801. SHLIB_CFLAGS=""
  1802. SHLIB_LD="ld -n32 -shared -rdata_shared"
  1803. SHLIB_LD_LIBS='${LIBS}'
  1804. SHLIB_SUFFIX=".so"
  1805. LDFLAGS=""
  1806. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  1807. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  1808. # Check to enable 64-bit flags for compiler/linker
  1809. if test "$do64bit" = "yes" ; then
  1810. if test "$GCC" = "yes" ; then
  1811. echo "configure: warning: 64bit mode not supported by gcc" 1>&2
  1812. else
  1813. do64bit_ok=yes
  1814. SHLIB_LD="ld -64 -shared -rdata_shared"
  1815. EXTRA_CFLAGS="-64"
  1816. LDFLAGS="-64"
  1817. fi
  1818. fi
  1819. ;;
  1820. Linux*)
  1821. SHLIB_CFLAGS="-fPIC"
  1822. SHLIB_LD_LIBS='${LIBS}'
  1823. SHLIB_SUFFIX=".so"
  1824. CFLAGS_OPTIMIZE=-O2
  1825. # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings
  1826. # when you inline the string and math operations. Turn this off to
  1827. # get rid of the warnings.
  1828. #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES"
  1829. if test "$have_dl" = yes; then
  1830. SHLIB_LD="${CC} -shared"
  1831. LDFLAGS="-Wl,--export-dynamic"
  1832. CC_SEARCH_FLAGS='-Wl,-rpath-link,${LIB_RUNTIME_DIR}'
  1833. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  1834. else
  1835. ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'`
  1836. echo $ac_n "checking for dld.h""... $ac_c" 1>&6
  1837. echo "configure:2087: checking for dld.h" >&5
  1838. cat > conftest.$ac_ext <<EOF
  1839. #line 2090 "configure"
  1840. #include "confdefs.h"
  1841. #include <dld.h>
  1842. EOF
  1843. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1844. { (eval echo configure:2095: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  1845. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  1846. if test -z "$ac_err"; then
  1847. rm -rf conftest*
  1848. eval "ac_cv_header_$ac_safe=yes"
  1849. else
  1850. echo "$ac_err" >&5
  1851. echo "configure: failed program was:" >&5
  1852. cat conftest.$ac_ext >&5
  1853. rm -rf conftest*
  1854. eval "ac_cv_header_$ac_safe=no"
  1855. fi
  1856. rm -f conftest*
  1857. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  1858. echo "$ac_t""yes" 1>&6
  1859. SHLIB_LD="ld -shared"
  1860. LDFLAGS=""
  1861. CC_SEARCH_FLAGS=""
  1862. LD_SEARCH_FLAGS=""
  1863. else
  1864. echo "$ac_t""no" 1>&6
  1865. fi
  1866. fi
  1867. if test "`uname -m`" = "alpha" ; then
  1868. EXTRA_CFLAGS="-mieee"
  1869. fi
  1870. # The combo of gcc + glibc has a bug related
  1871. # to inlining of functions like strtod(). The
  1872. # -fno-builtin flag should address this problem
  1873. # but it does not work. The -fno-inline flag
  1874. # is kind of overkill but it works.
  1875. # Disable inlining only when one of the
  1876. # files in compat/*.c is being linked in.
  1877. if test x"${USE_COMPAT}" != x ; then
  1878. EXTRA_CFLAGS="${EXTRA_CFLAGS} -fno-inline"
  1879. fi
  1880. # XIM peeking works under XFree86.
  1881. cat >> confdefs.h <<\EOF
  1882. #define PEEK_XCLOSEIM 1
  1883. EOF
  1884. ;;
  1885. GNU*)
  1886. SHLIB_CFLAGS="-fPIC"
  1887. SHLIB_LD_LIBS='${LIBS}'
  1888. SHLIB_SUFFIX=".so"
  1889. if test "$have_dl" = yes; then
  1890. SHLIB_LD="${CC} -shared"
  1891. LDFLAGS="-Wl,--export-dynamic"
  1892. CC_SEARCH_FLAGS=""
  1893. LD_SEARCH_FLAGS=""
  1894. else
  1895. ac_safe=`echo "dld.h" | sed 'y%./+-%__p_%'`
  1896. echo $ac_n "checking for dld.h""... $ac_c" 1>&6
  1897. echo "configure:2155: checking for dld.h" >&5
  1898. cat > conftest.$ac_ext <<EOF
  1899. #line 2158 "configure"
  1900. #include "confdefs.h"
  1901. #include <dld.h>
  1902. EOF
  1903. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  1904. { (eval echo configure:2163: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  1905. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  1906. if test -z "$ac_err"; then
  1907. rm -rf conftest*
  1908. eval "ac_cv_header_$ac_safe=yes"
  1909. else
  1910. echo "$ac_err" >&5
  1911. echo "configure: failed program was:" >&5
  1912. cat conftest.$ac_ext >&5
  1913. rm -rf conftest*
  1914. eval "ac_cv_header_$ac_safe=no"
  1915. fi
  1916. rm -f conftest*
  1917. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  1918. echo "$ac_t""yes" 1>&6
  1919. SHLIB_LD="ld -shared"
  1920. LDFLAGS=""
  1921. CC_SEARCH_FLAGS=""
  1922. LD_SEARCH_FLAGS=""
  1923. else
  1924. echo "$ac_t""no" 1>&6
  1925. fi
  1926. fi
  1927. if test "`uname -m`" = "alpha" ; then
  1928. EXTRA_CFLAGS="-mieee"
  1929. fi
  1930. ;;
  1931. CYGWIN*)
  1932. SHLIB_CFLAGS=""
  1933. SHLIB_LD_LIBS='${LIBS}'
  1934. SHLIB_SUFFIX=".dll"
  1935. SHLIB_LD="${CC} -shared"
  1936. LDFLAGS="-Wl,--export-dynamic"
  1937. CC_SEARCH_FLAGS=""
  1938. LD_SEARCH_FLAGS=""
  1939. LD_LIBRARY_PATH_VAR="PATH"
  1940. ;;
  1941. MINGW*)
  1942. SHLIB_CFLAGS=""
  1943. SHLIB_LD_LIBS='${LIBS}'
  1944. SHLIB_SUFFIX=".dll"
  1945. SHLIB_LD="${CC} -shared"
  1946. LDFLAGS="-Wl,--export-dynamic,--enable-runtime-pseudo-reloc"
  1947. CC_SEARCH_FLAGS=""
  1948. LD_SEARCH_FLAGS=""
  1949. LD_LIBRARY_PATH_VAR="PATH"
  1950. ;;
  1951. MP-RAS-02*)
  1952. SHLIB_CFLAGS="-K PIC"
  1953. SHLIB_LD="cc -G"
  1954. SHLIB_LD_LIBS=""
  1955. SHLIB_SUFFIX=".so"
  1956. LDFLAGS=""
  1957. CC_SEARCH_FLAGS=""
  1958. LD_SEARCH_FLAGS=""
  1959. ;;
  1960. MP-RAS-*)
  1961. SHLIB_CFLAGS="-K PIC"
  1962. SHLIB_LD="cc -G"
  1963. SHLIB_LD_LIBS=""
  1964. SHLIB_SUFFIX=".so"
  1965. LDFLAGS="-Wl,-Bexport"
  1966. CC_SEARCH_FLAGS=""
  1967. LD_SEARCH_FLAGS=""
  1968. ;;
  1969. NetBSD-*)
  1970. # NetBSD has ELF.
  1971. SHLIB_CFLAGS="-fPIC"
  1972. SHLIB_LD="ld -Bshareable -x"
  1973. SHLIB_LD_LIBS="${LIBS}"
  1974. SHLIB_SUFFIX=".so"
  1975. LDFLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR} -export-dynamic'
  1976. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  1977. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  1978. if test "${GRASS_THREADS}" = "1" ; then
  1979. # The -pthread needs to go in the CFLAGS, not LIBS
  1980. LIBS=`echo $LIBS | sed s/-pthread//`
  1981. EXTRA_CFLAGS="-pthread"
  1982. LDFLAGS="$LDFLAGS -pthread"
  1983. fi
  1984. # NetBSD doesn't handle version numbers with dots.
  1985. UNSHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.a'
  1986. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so',
  1987. GRASS_LIB_VERSIONS_OK=nodots
  1988. ;;
  1989. OpenBSD-*)
  1990. SHLIB_LD="${CC} -shared"
  1991. SHLIB_LD_LIBS='${LIBS}'
  1992. SHLIB_SUFFIX=".so"
  1993. LDFLAGS=""
  1994. CC_SEARCH_FLAGS=""
  1995. LD_SEARCH_FLAGS=""
  1996. echo $ac_n "checking for ELF""... $ac_c" 1>&6
  1997. echo "configure:2260: checking for ELF" >&5
  1998. cat > conftest.$ac_ext <<EOF
  1999. #line 2262 "configure"
  2000. #include "confdefs.h"
  2001. #ifdef __ELF__
  2002. yes
  2003. #endif
  2004. EOF
  2005. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  2006. egrep "yes" >/dev/null 2>&1; then
  2007. rm -rf conftest*
  2008. echo "$ac_t""yes" 1>&6
  2009. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so.1.0'
  2010. else
  2011. rm -rf conftest*
  2012. echo "$ac_t""no" 1>&6
  2013. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so.1.0'
  2014. fi
  2015. rm -f conftest*
  2016. # OpenBSD doesn't do version numbers with dots.
  2017. UNSHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.a'
  2018. GRASS_LIB_VERSIONS_OK=nodots
  2019. ;;
  2020. FreeBSD-[1-2].*)
  2021. # Not available on all versions: check for include file.
  2022. ac_safe=`echo "dlfcn.h" | sed 'y%./+-%__p_%'`
  2023. echo $ac_n "checking for dlfcn.h""... $ac_c" 1>&6
  2024. echo "configure:2292: checking for dlfcn.h" >&5
  2025. cat > conftest.$ac_ext <<EOF
  2026. #line 2295 "configure"
  2027. #include "confdefs.h"
  2028. #include <dlfcn.h>
  2029. EOF
  2030. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  2031. { (eval echo configure:2300: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  2032. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  2033. if test -z "$ac_err"; then
  2034. rm -rf conftest*
  2035. eval "ac_cv_header_$ac_safe=yes"
  2036. else
  2037. echo "$ac_err" >&5
  2038. echo "configure: failed program was:" >&5
  2039. cat conftest.$ac_ext >&5
  2040. rm -rf conftest*
  2041. eval "ac_cv_header_$ac_safe=no"
  2042. fi
  2043. rm -f conftest*
  2044. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  2045. echo "$ac_t""yes" 1>&6
  2046. SHLIB_CFLAGS="-fPIC"
  2047. SHLIB_LD="ld -Bshareable -x"
  2048. SHLIB_LD_LIBS=""
  2049. SHLIB_SUFFIX=".so"
  2050. LDFLAGS=""
  2051. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  2052. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  2053. echo $ac_n "checking for ELF""... $ac_c" 1>&6
  2054. echo "configure:2324: checking for ELF" >&5
  2055. cat > conftest.$ac_ext <<EOF
  2056. #line 2326 "configure"
  2057. #include "confdefs.h"
  2058. #ifdef __ELF__
  2059. yes
  2060. #endif
  2061. EOF
  2062. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  2063. egrep "yes" >/dev/null 2>&1; then
  2064. rm -rf conftest*
  2065. echo "$ac_t""yes" 1>&6
  2066. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so'
  2067. else
  2068. rm -rf conftest*
  2069. echo "$ac_t""no" 1>&6
  2070. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so.1.0'
  2071. fi
  2072. rm -f conftest*
  2073. else
  2074. echo "$ac_t""no" 1>&6
  2075. SHLIB_CFLAGS=""
  2076. SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r"
  2077. SHLIB_LD_LIBS='${LIBS}'
  2078. SHLIB_SUFFIX=".a"
  2079. LDFLAGS=""
  2080. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  2081. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2082. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.a'
  2083. fi
  2084. UNSHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.a'
  2085. GRASS_LIB_VERSIONS_OK=nodots
  2086. ;;
  2087. FreeBSD-*)
  2088. # FreeBSD 3.* and greater have ELF.
  2089. SHLIB_CFLAGS="-fPIC"
  2090. SHLIB_LD="ld -Bshareable -x"
  2091. SHLIB_LD_LIBS='${LIBS}'
  2092. SHLIB_SUFFIX=".so"
  2093. LDFLAGS="-export-dynamic"
  2094. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  2095. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  2096. if test "${GRASS_THREADS}" = "1" ; then
  2097. # The -pthread needs to go in the CFLAGS, not LIBS
  2098. LIBS=`echo $LIBS | sed s/-pthread//`
  2099. EXTRA_CFLAGS="-pthread"
  2100. LDFLAGS="$LDFLAGS -pthread"
  2101. fi
  2102. case $system in
  2103. FreeBSD-3.*)
  2104. # FreeBSD-3 doesn't handle version numbers with dots.
  2105. UNSHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.a'
  2106. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so'
  2107. GRASS_LIB_VERSIONS_OK=nodots
  2108. ;;
  2109. esac
  2110. ;;
  2111. Rhapsody-*|Darwin-*)
  2112. SHLIB_CFLAGS="-fno-common"
  2113. SHLIB_LD="cc -dynamiclib -compatibility_version \${GRASS_VERSION_MAJOR}.\${GRASS_VERSION_MINOR} -current_version \${GRASS_VERSION_MAJOR}.\${GRASS_VERSION_MINOR} -install_name \${INST_DIR}/lib/lib\${LIB_NAME}\${SHLIB_SUFFIX}"
  2114. GRASS_SHLIB_LD_EXTRAS=""
  2115. SHLIB_LD_LIBS='${LIBS}'
  2116. SHLIB_SUFFIX=".dylib"
  2117. PLAT_OBJS=""
  2118. CC_SEARCH_FLAGS=""
  2119. LD_SEARCH_FLAGS=""
  2120. CFLAGS_OPTIMIZE="-Os"
  2121. LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH"
  2122. # for compatibility with autoconf vers 2.13 :
  2123. HACK=""
  2124. EXTRA_CFLAGS=""
  2125. LIBS="$LIBS"
  2126. ;;
  2127. NEXTSTEP-*)
  2128. SHLIB_CFLAGS=""
  2129. SHLIB_LD="cc -nostdlib -r"
  2130. SHLIB_LD_LIBS=""
  2131. SHLIB_SUFFIX=".so"
  2132. LDFLAGS=""
  2133. CC_SEARCH_FLAGS=""
  2134. LD_SEARCH_FLAGS=""
  2135. ;;
  2136. OS/390-*)
  2137. CFLAGS_OPTIMIZE="" # Optimizer is buggy
  2138. cat >> confdefs.h <<\EOF
  2139. #define _OE_SOCKETS 1
  2140. EOF
  2141. # needed in sys/socket.h
  2142. ;;
  2143. OSF1-1.0|OSF1-1.1|OSF1-1.2)
  2144. # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1
  2145. SHLIB_CFLAGS=""
  2146. # Hack: make package name same as library name
  2147. SHLIB_LD='ld -R -export :'
  2148. SHLIB_LD_LIBS=""
  2149. SHLIB_SUFFIX=".so"
  2150. LDFLAGS=""
  2151. CC_SEARCH_FLAGS=""
  2152. LD_SEARCH_FLAGS=""
  2153. ;;
  2154. OSF1-1.*)
  2155. # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2
  2156. SHLIB_CFLAGS="-fPIC"
  2157. if test "$SHARED_BUILD" = "1" ; then
  2158. SHLIB_LD="ld -shared"
  2159. else
  2160. SHLIB_LD="ld -non_shared"
  2161. fi
  2162. SHLIB_LD_LIBS=""
  2163. SHLIB_SUFFIX=".so"
  2164. LDFLAGS=""
  2165. CC_SEARCH_FLAGS=""
  2166. LD_SEARCH_FLAGS=""
  2167. ;;
  2168. OSF1-V*)
  2169. # Digital OSF/1
  2170. SHLIB_CFLAGS=""
  2171. if test "$SHARED_BUILD" = "1" ; then
  2172. SHLIB_LD='ld -shared -expect_unresolved "*"'
  2173. else
  2174. SHLIB_LD='ld -non_shared -expect_unresolved "*"'
  2175. fi
  2176. SHLIB_LD_LIBS=""
  2177. SHLIB_SUFFIX=".so"
  2178.  LDFLAGS=""
  2179. CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
  2180. LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}'
  2181. if test "$GCC" = "yes" ; then
  2182. EXTRA_CFLAGS="-mieee"
  2183. else
  2184. EXTRA_CFLAGS="-DHAVE_TZSET -std1 -ieee"
  2185. fi
  2186. # see pthread_intro(3) for pthread support on osf1, k.furukawa
  2187. if test "${GRASS_THREADS}" = "1" ; then
  2188. EXTRA_CFLAGS="${EXTRA_CFLAGS} -DHAVE_PTHREAD_ATTR_SETSTACKSIZE"
  2189. EXTRA_CFLAGS="${EXTRA_CFLAGS} -DGRASS_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64"
  2190. LIBS=`echo $LIBS | sed s/-lpthreads//`
  2191. if test "$GCC" = "yes" ; then
  2192. LIBS="$LIBS -lpthread -lmach -lexc"
  2193. else
  2194. EXTRA_CFLAGS="${EXTRA_CFLAGS} -pthread"
  2195. LDFLAGS="-pthread"
  2196. fi
  2197. fi
  2198. ;;
  2199. QNX-6*)
  2200. # QNX RTP
  2201. # This may work for all QNX, but it was only reported for v6.
  2202. SHLIB_CFLAGS="-fPIC"
  2203. SHLIB_LD="ld -Bshareable -x"
  2204. SHLIB_LD_LIBS=""
  2205. SHLIB_SUFFIX=".so"
  2206. LDFLAGS=""
  2207. CC_SEARCH_FLAGS=""
  2208. LD_SEARCH_FLAGS=""
  2209. ;;
  2210. RISCos-*)
  2211. SHLIB_CFLAGS="-G 0"
  2212. SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
  2213. SHLIB_LD_LIBS='${LIBS}'
  2214. SHLIB_SUFFIX=".a"
  2215. LDFLAGS="-Wl,-D,08000000"
  2216. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  2217. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2218. ;;
  2219. SCO_SV-3.2*)
  2220. # Note, dlopen is available only on SCO 3.2.5 and greater. However,
  2221. # this test works, since "uname -s" was non-standard in 3.2.4 and
  2222. # below.
  2223. if test "$GCC" = "yes" ; then
  2224. SHLIB_CFLAGS="-fPIC -melf"
  2225. LDFLAGS="-melf -Wl,-Bexport"
  2226. else
  2227. SHLIB_CFLAGS="-Kpic -belf"
  2228. LDFLAGS="-belf -Wl,-Bexport"
  2229. fi
  2230. SHLIB_LD="ld -G"
  2231. SHLIB_LD_LIBS=""
  2232. SHLIB_SUFFIX=".so"
  2233. CC_SEARCH_FLAGS=""
  2234. LD_SEARCH_FLAGS=""
  2235. ;;
  2236. SINIX*5.4*)
  2237. SHLIB_CFLAGS="-K PIC"
  2238. SHLIB_LD="cc -G"
  2239. SHLIB_LD_LIBS=""
  2240. SHLIB_SUFFIX=".so"
  2241. LDFLAGS=""
  2242. CC_SEARCH_FLAGS=""
  2243. LD_SEARCH_FLAGS=""
  2244. ;;
  2245. SunOS-4*)
  2246. SHLIB_CFLAGS="-PIC"
  2247. SHLIB_LD="ld"
  2248. SHLIB_LD_LIBS=""
  2249. SHLIB_SUFFIX=".so"
  2250. LDFLAGS=""
  2251. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  2252. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2253. # SunOS can't handle version numbers with dots in them in library
  2254. # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it
  2255. # requires an extra version number at the end of .so file names.
  2256. # So, the library has to have a name like libtcl75.so.1.0
  2257. SHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.so.1.0'
  2258. UNSHARED_LIB_SUFFIX='${GRASS_TRIM_DOTS}.a'
  2259. GRASS_LIB_VERSIONS_OK=nodots
  2260. ;;
  2261. SunOS-5.[0-6].*)
  2262. # Note: If _REENTRANT isn't defined, then Solaris
  2263. # won't define thread-safe library routines.
  2264. cat >> confdefs.h <<\EOF
  2265. #define _REENTRANT 1
  2266. EOF
  2267. cat >> confdefs.h <<\EOF
  2268. #define _POSIX_PTHREAD_SEMANTICS 1
  2269. EOF
  2270. # Note: need the LIBS below, otherwise Tk won't find Tcl's
  2271. # symbols when dynamically loaded into tclsh.
  2272. SHLIB_LD_LIBS='${LIBS}'
  2273. SHLIB_SUFFIX=".so"
  2274. LDFLAGS=""
  2275. if test "$GCC" = "yes" ; then
  2276. SHLIB_CFLAGS="-fPIC"
  2277. SHLIB_LD="$CC -shared"
  2278. CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
  2279. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2280. else
  2281. SHLIB_CFLAGS="-KPIC"
  2282. SHLIB_LD="/usr/ccs/bin/ld -G -z text"
  2283. CC_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
  2284. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2285. fi
  2286. ;;
  2287. SunOS-5*)
  2288. # Note: If _REENTRANT isn't defined, then Solaris
  2289. # won't define thread-safe library routines.
  2290. cat >> confdefs.h <<\EOF
  2291. #define _REENTRANT 1
  2292. EOF
  2293. cat >> confdefs.h <<\EOF
  2294. #define _POSIX_PTHREAD_SEMANTICS 1
  2295. EOF
  2296. LDFLAGS=""
  2297. # Check to enable 64-bit flags for compiler/linker
  2298. if test "$do64bit" = "yes" ; then
  2299. arch=`isainfo`
  2300. if test "$arch" = "sparcv9 sparc" ; then
  2301. if test "$GCC" = "yes" ; then
  2302. echo "configure: warning: "64bit mode not supported with GCC on $system"" 1>&2
  2303. else
  2304. SHLIB_CFLAGS="-KPIC"
  2305. do64bit_ok=yes
  2306. if test "$do64bitVIS" = "yes" ; then
  2307. EXTRA_CFLAGS="-xarch=v9a"
  2308. LDFLAGS="-xarch=v9a"
  2309. else
  2310. EXTRA_CFLAGS="-xarch=v9"
  2311. LDFLAGS="-xarch=v9"
  2312. fi
  2313. fi
  2314. else
  2315. echo "configure: warning: "64bit mode only supported sparcv9 system"" 1>&2
  2316. fi
  2317. fi
  2318. # Note: need the LIBS below, otherwise Tk won't find Tcl's
  2319. # symbols when dynamically loaded into tclsh.
  2320. SHLIB_LD_LIBS='${LIBS}'
  2321. SHLIB_SUFFIX=".so"
  2322. if test "$GCC" = "yes" ; then
  2323. SHLIB_CFLAGS="-fPIC"
  2324. SHLIB_LD="$CC -shared"
  2325. CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
  2326. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2327. else
  2328. SHLIB_CFLAGS="-KPIC"
  2329. SHLIB_LD="CC -G -z text"
  2330. CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}'
  2331. LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
  2332. fi
  2333. ;;
  2334. ULTRIX-4.*)
  2335. SHLIB_CFLAGS="-G 0"
  2336. SHLIB_SUFFIX=".a"
  2337. SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0"
  2338. SHLIB_LD_LIBS='${LIBS}'
  2339. LDFLAGS="-Wl,-D,08000000"
  2340. CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}'
  2341. LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS}
  2342. if test "$GCC" != "yes" ; then
  2343. EXTRA_CFLAGS="-DHAVE_TZSET -std1"
  2344. fi
  2345. ;;
  2346. UNIX_SV* | UnixWare-5*)
  2347. SHLIB_CFLAGS="-KPIC"
  2348. SHLIB_LD="cc -G"
  2349. SHLIB_LD_LIBS=""
  2350. SHLIB_SUFFIX=".so"
  2351. # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers
  2352. # that don't grok the -Bexport option. Test that it does.
  2353. hold_ldflags=$LDFLAGS
  2354. echo $ac_n "checking for ld accepts -Bexport flag""... $ac_c" 1>&6
  2355. echo "configure:2650: checking for ld accepts -Bexport flag" >&5
  2356. LDFLAGS="${LDFLAGS} -Wl,-Bexport"
  2357. cat > conftest.$ac_ext <<EOF
  2358. #line 2653 "configure"
  2359. #include "confdefs.h"
  2360. int main() {
  2361. int i;
  2362. ; return 0; }
  2363. EOF
  2364. if { (eval echo configure:2660: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  2365. rm -rf conftest*
  2366. found=yes
  2367. else
  2368. echo "configure: failed program was:" >&5
  2369. cat conftest.$ac_ext >&5
  2370. rm -rf conftest*
  2371. found=no
  2372. fi
  2373. rm -f conftest*
  2374. LDFLAGS=$hold_ldflags
  2375. echo "$ac_t""$found" 1>&6
  2376. if test $found = yes; then
  2377. LDFLAGS="-Wl,-Bexport"
  2378. else
  2379. LDFLAGS=""
  2380. fi
  2381. CC_SEARCH_FLAGS=""
  2382. LD_SEARCH_FLAGS=""
  2383. ;;
  2384. esac
  2385. # If we're running gcc, then change the C flags for compiling shared
  2386. # libraries to the right flags for gcc, instead of those for the
  2387. # standard manufacturer compiler.
  2388. if test "$GCC" = "yes" ; then
  2389. case $system in
  2390. AIX-*)
  2391. ;;
  2392. BSD/OS*)
  2393. ;;
  2394. *)
  2395. ;;
  2396. NetBSD-*|FreeBSD-*)
  2397. ;;
  2398. Rhapsody-*|Darwin-*)
  2399. ;;
  2400. RISCos-*)
  2401. ;;
  2402. SCO_SV-3.2*)
  2403. ;;
  2404. ULTRIX-4.*)
  2405. ;;
  2406. *)
  2407. SHLIB_CFLAGS="-fPIC"
  2408. ;;
  2409. esac
  2410. fi
  2411. if test "$SHARED_LIB_SUFFIX" = "" ; then
  2412. SHARED_LIB_SUFFIX='${LIB_VER}${SHLIB_SUFFIX}'
  2413. fi
  2414. if test "$UNSHARED_LIB_SUFFIX" = "" ; then
  2415. UNSHARED_LIB_SUFFIX='${LIB_VER}.a'
  2416. fi
  2417. if test "${SHARED_BUILD}" = "1" && test "${SHLIB_SUFFIX}" != "" ; then
  2418. LIB_SUFFIX=${SHARED_LIB_SUFFIX}
  2419. MAKE_LIB='${SHLIB_LD} -o $@ ${SHLIB_LD_FLAGS} ${OBJS} ${SHLIB_LD_LIBS} ${GRASS_SHLIB_LD_EXTRAS} ${LD_SEARCH_FLAGS}'
  2420. INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) $(LIB_INSTALL_DIR)/$(LIB_FILE)'
  2421. else
  2422. LIB_SUFFIX=${UNSHARED_LIB_SUFFIX}
  2423. if test "$RANLIB" = "" ; then
  2424. MAKE_LIB='$(STLIB_LD) $@ ${OBJS}'
  2425. INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) $(LIB_INSTALL_DIR)/$(LIB_FILE)'
  2426. else
  2427. MAKE_LIB='${STLIB_LD} $@ ${OBJS} ; ${RANLIB} $@'
  2428. INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) $(LIB_INSTALL_DIR)/$(LIB_FILE) ; (cd $(LIB_INSTALL_DIR) ; $(RANLIB) $(LIB_FILE))'
  2429. fi
  2430. fi
  2431. # Stub lib does not depend on shared/static configuration
  2432. if test "$RANLIB" = "" ; then
  2433. MAKE_STUB_LIB='${STLIB_LD} $@ ${STUB_LIB_OBJS}'
  2434. INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) $(LIB_INSTALL_DIR)/$(STUB_LIB_FILE)'
  2435. else
  2436. MAKE_STUB_LIB='${STLIB_LD} $@ ${STUB_LIB_OBJS} ; ${RANLIB} $@'
  2437. INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) $(LIB_INSTALL_DIR)/$(STUB_LIB_FILE) ; (cd $(LIB_INSTALL_DIR) ; $(RANLIB) $(STUB_LIB_FILE))'
  2438. fi
  2439. LDFLAGS="${ac_save_ldflags} $LDFLAGS"
  2440. # Enable options
  2441. # Check whether --enable-w11 or --disable-w11 was given.
  2442. if test "${enable_w11+set}" = set; then
  2443. enableval="$enable_w11"
  2444. :
  2445. else
  2446. enable_w11=no
  2447. fi
  2448. # With options
  2449. # Check whether --with-cxx or --without-cxx was given.
  2450. if test "${with_cxx+set}" = set; then
  2451. withval="$with_cxx"
  2452. :
  2453. else
  2454. with_cxx=no
  2455. fi
  2456. #LOC_ARG_WITH(g77, GNU Fortran 77, no)
  2457. # Check whether --with-jpeg or --without-jpeg was given.
  2458. if test "${with_jpeg+set}" = set; then
  2459. withval="$with_jpeg"
  2460. :
  2461. else
  2462. with_jpeg=yes
  2463. fi
  2464. # Check whether --with-tiff or --without-tiff was given.
  2465. if test "${with_tiff+set}" = set; then
  2466. withval="$with_tiff"
  2467. :
  2468. else
  2469. with_tiff=yes
  2470. fi
  2471. # Check whether --with-png or --without-png was given.
  2472. if test "${with_png+set}" = set; then
  2473. withval="$with_png"
  2474. :
  2475. else
  2476. with_png=yes
  2477. fi
  2478. # Check whether --with-tcltk or --without-tcltk was given.
  2479. if test "${with_tcltk+set}" = set; then
  2480. withval="$with_tcltk"
  2481. :
  2482. else
  2483. with_tcltk=yes
  2484. fi
  2485. # Check whether --with-postgres or --without-postgres was given.
  2486. if test "${with_postgres+set}" = set; then
  2487. withval="$with_postgres"
  2488. :
  2489. else
  2490. with_postgres=no
  2491. fi
  2492. # Check whether --with-mysql or --without-mysql was given.
  2493. if test "${with_mysql+set}" = set; then
  2494. withval="$with_mysql"
  2495. :
  2496. else
  2497. with_mysql=no
  2498. fi
  2499. # Check whether --with-sqlite or --without-sqlite was given.
  2500. if test "${with_sqlite+set}" = set; then
  2501. withval="$with_sqlite"
  2502. :
  2503. else
  2504. with_sqlite=no
  2505. fi
  2506. # Check whether --with-ffmpeg or --without-ffmpeg was given.
  2507. if test "${with_ffmpeg+set}" = set; then
  2508. withval="$with_ffmpeg"
  2509. :
  2510. else
  2511. with_ffmpeg=no
  2512. fi
  2513. # Check whether --with-opengl or --without-opengl was given.
  2514. if test "${with_opengl+set}" = set; then
  2515. withval="$with_opengl"
  2516. :
  2517. else
  2518. with_opengl=yes
  2519. fi
  2520. # Check whether --with-odbc or --without-odbc was given.
  2521. if test "${with_odbc+set}" = set; then
  2522. withval="$with_odbc"
  2523. :
  2524. else
  2525. with_odbc=no
  2526. fi
  2527. # Check whether --with-fftw or --without-fftw was given.
  2528. if test "${with_fftw+set}" = set; then
  2529. withval="$with_fftw"
  2530. :
  2531. else
  2532. with_fftw=yes
  2533. fi
  2534. # Check whether --with-blas or --without-blas was given.
  2535. if test "${with_blas+set}" = set; then
  2536. withval="$with_blas"
  2537. :
  2538. else
  2539. with_blas=no
  2540. fi
  2541. # Check whether --with-lapack or --without-lapack was given.
  2542. if test "${with_lapack+set}" = set; then
  2543. withval="$with_lapack"
  2544. :
  2545. else
  2546. with_lapack=no
  2547. fi
  2548. # Check whether --with-cairo or --without-cairo was given.
  2549. if test "${with_cairo+set}" = set; then
  2550. withval="$with_cairo"
  2551. :
  2552. else
  2553. with_cairo=yes
  2554. fi
  2555. # Check whether --with-freetype or --without-freetype was given.
  2556. if test "${with_freetype+set}" = set; then
  2557. withval="$with_freetype"
  2558. :
  2559. else
  2560. with_freetype=yes
  2561. fi
  2562. # Check whether --with-nls or --without-nls was given.
  2563. if test "${with_nls+set}" = set; then
  2564. withval="$with_nls"
  2565. :
  2566. else
  2567. with_nls=no
  2568. fi
  2569. # Check whether --with-readline or --without-readline was given.
  2570. if test "${with_readline+set}" = set; then
  2571. withval="$with_readline"
  2572. :
  2573. else
  2574. with_readline=no
  2575. fi
  2576. # Check whether --with-opendwg or --without-opendwg was given.
  2577. if test "${with_opendwg+set}" = set; then
  2578. withval="$with_opendwg"
  2579. :
  2580. else
  2581. with_opendwg=no
  2582. fi
  2583. # Check whether --with-regex or --without-regex was given.
  2584. if test "${with_regex+set}" = set; then
  2585. withval="$with_regex"
  2586. :
  2587. else
  2588. with_regex=yes
  2589. fi
  2590. # Check whether --with-pthread or --without-pthread was given.
  2591. if test "${with_pthread+set}" = set; then
  2592. withval="$with_pthread"
  2593. :
  2594. else
  2595. with_pthread=no
  2596. fi
  2597. # Check whether --with-gdal or --without-gdal was given.
  2598. if test "${with_gdal+set}" = set; then
  2599. withval="$with_gdal"
  2600. :
  2601. fi
  2602. # Check whether --with-python or --without-python was given.
  2603. if test "${with_python+set}" = set; then
  2604. withval="$with_python"
  2605. :
  2606. else
  2607. with_python="no"
  2608. fi
  2609. # Check whether --with-wxwidgets or --without-wxwidgets was given.
  2610. if test "${with_wxwidgets+set}" = set; then
  2611. withval="$with_wxwidgets"
  2612. :
  2613. else
  2614. with_wxwidgets="no"
  2615. fi
  2616. # With includes and libs options
  2617. # Check whether --with-geos or --without-geos was given.
  2618. if test "${with_geos+set}" = set; then
  2619. withval="$with_geos"
  2620. :
  2621. else
  2622. with_geos="no"
  2623. fi
  2624. # Check whether --with-includes or --without-includes was given.
  2625. if test "${with_includes+set}" = set; then
  2626. withval="$with_includes"
  2627. :
  2628. fi
  2629. # Check whether --with-libs or --without-libs was given.
  2630. if test "${with_libs+set}" = set; then
  2631. withval="$with_libs"
  2632. :
  2633. fi
  2634. # Check whether --with-zlib-includes or --without-zlib-includes was given.
  2635. if test "${with_zlib_includes+set}" = set; then
  2636. withval="$with_zlib_includes"
  2637. :
  2638. fi
  2639. # Check whether --with-zlib-libs or --without-zlib-libs was given.
  2640. if test "${with_zlib_libs+set}" = set; then
  2641. withval="$with_zlib_libs"
  2642. :
  2643. fi
  2644. # Check whether --with-readline-includes or --without-readline-includes was given.
  2645. if test "${with_readline_includes+set}" = set; then
  2646. withval="$with_readline_includes"
  2647. :
  2648. fi
  2649. # Check whether --with-readline-libs or --without-readline-libs was given.
  2650. if test "${with_readline_libs+set}" = set; then
  2651. withval="$with_readline_libs"
  2652. :
  2653. fi
  2654. # Check whether --with-jpeg-includes or --without-jpeg-includes was given.
  2655. if test "${with_jpeg_includes+set}" = set; then
  2656. withval="$with_jpeg_includes"
  2657. :
  2658. fi
  2659. # Check whether --with-jpeg-libs or --without-jpeg-libs was given.
  2660. if test "${with_jpeg_libs+set}" = set; then
  2661. withval="$with_jpeg_libs"
  2662. :
  2663. fi
  2664. # Check whether --with-tiff-includes or --without-tiff-includes was given.
  2665. if test "${with_tiff_includes+set}" = set; then
  2666. withval="$with_tiff_includes"
  2667. :
  2668. fi
  2669. # Check whether --with-tiff-libs or --without-tiff-libs was given.
  2670. if test "${with_tiff_libs+set}" = set; then
  2671. withval="$with_tiff_libs"
  2672. :
  2673. fi
  2674. # Check whether --with-png-includes or --without-png-includes was given.
  2675. if test "${with_png_includes+set}" = set; then
  2676. withval="$with_png_includes"
  2677. :
  2678. fi
  2679. # Check whether --with-png-libs or --without-png-libs was given.
  2680. if test "${with_png_libs+set}" = set; then
  2681. withval="$with_png_libs"
  2682. :
  2683. fi
  2684. # Check whether --with-tcltk-includes or --without-tcltk-includes was given.
  2685. if test "${with_tcltk_includes+set}" = set; then
  2686. withval="$with_tcltk_includes"
  2687. :
  2688. fi
  2689. # Check whether --with-tcltk-libs or --without-tcltk-libs was given.
  2690. if test "${with_tcltk_libs+set}" = set; then
  2691. withval="$with_tcltk_libs"
  2692. :
  2693. fi
  2694. # Check whether --with-postgres-includes or --without-postgres-includes was given.
  2695. if test "${with_postgres_includes+set}" = set; then
  2696. withval="$with_postgres_includes"
  2697. :
  2698. fi
  2699. # Check whether --with-postgres-libs or --without-postgres-libs was given.
  2700. if test "${with_postgres_libs+set}" = set; then
  2701. withval="$with_postgres_libs"
  2702. :
  2703. fi
  2704. # Check whether --with-mysql-includes or --without-mysql-includes was given.
  2705. if test "${with_mysql_includes+set}" = set; then
  2706. withval="$with_mysql_includes"
  2707. :
  2708. fi
  2709. # Check whether --with-mysql-libs or --without-mysql-libs was given.
  2710. if test "${with_mysql_libs+set}" = set; then
  2711. withval="$with_mysql_libs"
  2712. :
  2713. fi
  2714. # Check whether --with-sqlite-includes or --without-sqlite-includes was given.
  2715. if test "${with_sqlite_includes+set}" = set; then
  2716. withval="$with_sqlite_includes"
  2717. :
  2718. fi
  2719. # Check whether --with-sqlite-libs or --without-sqlite-libs was given.
  2720. if test "${with_sqlite_libs+set}" = set; then
  2721. withval="$with_sqlite_libs"
  2722. :
  2723. fi
  2724. # Check whether --with-ffmpeg-includes or --without-ffmpeg-includes was given.
  2725. if test "${with_ffmpeg_includes+set}" = set; then
  2726. withval="$with_ffmpeg_includes"
  2727. :
  2728. fi
  2729. # Check whether --with-ffmpeg-libs or --without-ffmpeg-libs was given.
  2730. if test "${with_ffmpeg_libs+set}" = set; then
  2731. withval="$with_ffmpeg_libs"
  2732. :
  2733. fi
  2734. # Check whether --with-opengl-includes or --without-opengl-includes was given.
  2735. if test "${with_opengl_includes+set}" = set; then
  2736. withval="$with_opengl_includes"
  2737. :
  2738. fi
  2739. # Check whether --with-opengl-libs or --without-opengl-libs was given.
  2740. if test "${with_opengl_libs+set}" = set; then
  2741. withval="$with_opengl_libs"
  2742. :
  2743. fi
  2744. # Check whether --with-opengl-framework or --without-opengl-framework was given.
  2745. if test "${with_opengl_framework+set}" = set; then
  2746. withval="$with_opengl_framework"
  2747. :
  2748. fi
  2749. # Check whether --with-odbc-includes or --without-odbc-includes was given.
  2750. if test "${with_odbc_includes+set}" = set; then
  2751. withval="$with_odbc_includes"
  2752. :
  2753. fi
  2754. # Check whether --with-odbc-libs or --without-odbc-libs was given.
  2755. if test "${with_odbc_libs+set}" = set; then
  2756. withval="$with_odbc_libs"
  2757. :
  2758. fi
  2759. # Check whether --with-fftw-includes or --without-fftw-includes was given.
  2760. if test "${with_fftw_includes+set}" = set; then
  2761. withval="$with_fftw_includes"
  2762. :
  2763. fi
  2764. # Check whether --with-fftw-libs or --without-fftw-libs was given.
  2765. if test "${with_fftw_libs+set}" = set; then
  2766. withval="$with_fftw_libs"
  2767. :
  2768. fi
  2769. # Check whether --with-blas-includes or --without-blas-includes was given.
  2770. if test "${with_blas_includes+set}" = set; then
  2771. withval="$with_blas_includes"
  2772. :
  2773. fi
  2774. # Check whether --with-blas-libs or --without-blas-libs was given.
  2775. if test "${with_blas_libs+set}" = set; then
  2776. withval="$with_blas_libs"
  2777. :
  2778. fi
  2779. # Check whether --with-lapack-includes or --without-lapack-includes was given.
  2780. if test "${with_lapack_includes+set}" = set; then
  2781. withval="$with_lapack_includes"
  2782. :
  2783. fi
  2784. # Check whether --with-lapack-libs or --without-lapack-libs was given.
  2785. if test "${with_lapack_libs+set}" = set; then
  2786. withval="$with_lapack_libs"
  2787. :
  2788. fi
  2789. # Check whether --with-cairo-includes or --without-cairo-includes was given.
  2790. if test "${with_cairo_includes+set}" = set; then
  2791. withval="$with_cairo_includes"
  2792. :
  2793. fi
  2794. # Check whether --with-cairo-libs or --without-cairo-libs was given.
  2795. if test "${with_cairo_libs+set}" = set; then
  2796. withval="$with_cairo_libs"
  2797. :
  2798. fi
  2799. # Check whether --with-cairo-ldflags or --without-cairo-ldflags was given.
  2800. if test "${with_cairo_ldflags+set}" = set; then
  2801. withval="$with_cairo_ldflags"
  2802. :
  2803. fi
  2804. # Check whether --with-freetype-includes or --without-freetype-includes was given.
  2805. if test "${with_freetype_includes+set}" = set; then
  2806. withval="$with_freetype_includes"
  2807. :
  2808. fi
  2809. # Check whether --with-freetype-libs or --without-freetype-libs was given.
  2810. if test "${with_freetype_libs+set}" = set; then
  2811. withval="$with_freetype_libs"
  2812. :
  2813. fi
  2814. # Check whether --with-proj-includes or --without-proj-includes was given.
  2815. if test "${with_proj_includes+set}" = set; then
  2816. withval="$with_proj_includes"
  2817. :
  2818. fi
  2819. # Check whether --with-proj-libs or --without-proj-libs was given.
  2820. if test "${with_proj_libs+set}" = set; then
  2821. withval="$with_proj_libs"
  2822. :
  2823. fi
  2824. # Check whether --with-proj-share or --without-proj-share was given.
  2825. if test "${with_proj_share+set}" = set; then
  2826. withval="$with_proj_share"
  2827. :
  2828. fi
  2829. # Check whether --with-opendwg-includes or --without-opendwg-includes was given.
  2830. if test "${with_opendwg_includes+set}" = set; then
  2831. withval="$with_opendwg_includes"
  2832. :
  2833. fi
  2834. # Check whether --with-opendwg-libs or --without-opendwg-libs was given.
  2835. if test "${with_opendwg_libs+set}" = set; then
  2836. withval="$with_opendwg_libs"
  2837. :
  2838. fi
  2839. # Check whether --with-regex-includes or --without-regex-includes was given.
  2840. if test "${with_regex_includes+set}" = set; then
  2841. withval="$with_regex_includes"
  2842. :
  2843. fi
  2844. # Check whether --with-regex-libs or --without-regex-libs was given.
  2845. if test "${with_regex_libs+set}" = set; then
  2846. withval="$with_regex_libs"
  2847. :
  2848. fi
  2849. # Check whether --with-pthread-includes or --without-pthread-includes was given.
  2850. if test "${with_pthread_includes+set}" = set; then
  2851. withval="$with_pthread_includes"
  2852. :
  2853. fi
  2854. # Check whether --with-pthread-libs or --without-pthread-libs was given.
  2855. if test "${with_pthread_libs+set}" = set; then
  2856. withval="$with_pthread_libs"
  2857. :
  2858. fi
  2859. # Put this early on so CPPFLAGS and LDFLAGS have any additional dirs
  2860. # With includes option
  2861. # Handle Fortran compiler choice
  2862. #LOC_CHECK_USE(g77, GNU Fortran 77, USE_G77)
  2863. # Done checking fortran
  2864. echo $ac_n "checking for additional include dirs""... $ac_c" 1>&6
  2865. echo "configure:3439: checking for additional include dirs" >&5
  2866. case "$with_includes" in
  2867. y | ye | yes | n | no)
  2868. { echo "configure: error: *** You must supply a directory to list --with-includes." 1>&2; exit 1; }
  2869. ;;
  2870. esac
  2871. echo "$ac_t""$with_includes" 1>&6
  2872. if test -n "$with_includes"; then
  2873. for dir in $with_includes; do
  2874. if test -d "$dir"; then
  2875. INCLUDE_DIRS="$INCLUDE_DIRS -I$dir"
  2876. else
  2877. { echo "configure: error: *** Include directory $dir does not exist." 1>&2; exit 1; }
  2878. fi
  2879. done
  2880. CPPFLAGS="$CPPFLAGS $INCLUDE_DIRS"
  2881. fi
  2882. # With libs option
  2883. echo $ac_n "checking for additional library dirs""... $ac_c" 1>&6
  2884. echo "configure:3462: checking for additional library dirs" >&5
  2885. case "$with_libs" in
  2886. y | ye | yes | n | no)
  2887. { echo "configure: error: *** You must supply a directory list to --with-libs." 1>&2; exit 1; }
  2888. ;;
  2889. esac
  2890. echo "$ac_t""$with_libs" 1>&6
  2891. if test -n "$with_libs"; then
  2892. for dir in $with_libs; do
  2893. if test -d "$dir"; then
  2894. LIBRARY_DIRS="$LIBRARY_DIRS -L$dir"
  2895. else
  2896. { echo "configure: error: *** Library directory $dir does not exist." 1>&2; exit 1; }
  2897. fi
  2898. done
  2899. LDFLAGS="$LDFLAGS $LIBRARY_DIRS"
  2900. fi
  2901. # Programs and standard headers, libraries, functions
  2902. # Find a good install program. We prefer a C program (faster),
  2903. # so one script is as good as another. But avoid the broken or
  2904. # incompatible versions:
  2905. # SysV /etc/install, /usr/sbin/install
  2906. # SunOS /usr/etc/install
  2907. # IRIX /sbin/install
  2908. # AIX /bin/install
  2909. # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
  2910. # AFS /usr/afsws/bin/install, which mishandles nonexistent args
  2911. # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
  2912. # ./install, which can be erroneously created by make from ./install.sh.
  2913. echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
  2914. echo "configure:3496: checking for a BSD compatible install" >&5
  2915. if test -z "$INSTALL"; then
  2916. IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
  2917. for ac_dir in $PATH; do
  2918. # Account for people who put trailing slashes in PATH elements.
  2919. case "$ac_dir/" in
  2920. /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
  2921. *)
  2922. # OSF1 and SCO ODT 3.0 have their own names for install.
  2923. # Don't use installbsd from OSF since it installs stuff as root
  2924. # by default.
  2925. for ac_prog in ginstall scoinst install; do
  2926. if test -f $ac_dir/$ac_prog; then
  2927. if test $ac_prog = install &&
  2928. grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
  2929. # AIX install. It has an incompatible calling convention.
  2930. :
  2931. else
  2932. ac_cv_path_install="$ac_dir/$ac_prog -c"
  2933. break 2
  2934. fi
  2935. fi
  2936. done
  2937. ;;
  2938. esac
  2939. done
  2940. IFS="$ac_save_IFS"
  2941. if test "${ac_cv_path_install+set}" = set; then
  2942. INSTALL="$ac_cv_path_install"
  2943. else
  2944. # As a last resort, use the slow shell script. We don't cache a
  2945. # path for INSTALL within a source directory, because that will
  2946. # break other packages using the cache if that directory is
  2947. # removed, or if the path is relative.
  2948. INSTALL="$ac_install_sh"
  2949. fi
  2950. fi
  2951. echo "$ac_t""$INSTALL" 1>&6
  2952. # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
  2953. # It thinks the first close brace ends the variable substitution.
  2954. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
  2955. test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
  2956. test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
  2957. # Extract the first word of "flex", so it can be a program name with args.
  2958. set dummy flex; ac_word=$2
  2959. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  2960. echo "configure:3549: checking for $ac_word" >&5
  2961. if test -n "$LEX"; then
  2962. ac_cv_prog_LEX="$LEX" # Let the user override the test.
  2963. else
  2964. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  2965. ac_dummy="$PATH"
  2966. for ac_dir in $ac_dummy; do
  2967. test -z "$ac_dir" && ac_dir=.
  2968. if test -f $ac_dir/$ac_word; then
  2969. ac_cv_prog_LEX="flex"
  2970. break
  2971. fi
  2972. done
  2973. IFS="$ac_save_ifs"
  2974. test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
  2975. fi
  2976. LEX="$ac_cv_prog_LEX"
  2977. if test -n "$LEX"; then
  2978. echo "$ac_t""$LEX" 1>&6
  2979. else
  2980. echo "$ac_t""no" 1>&6
  2981. fi
  2982. if test -z "$LEXLIB"
  2983. then
  2984. case "$LEX" in
  2985. flex*) ac_lib=fl ;;
  2986. *) ac_lib=l ;;
  2987. esac
  2988. echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
  2989. echo "configure:3580: checking for yywrap in -l$ac_lib" >&5
  2990. ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
  2991. ac_save_LIBS="$LIBS"
  2992. LIBS="-l$ac_lib $LIBS"
  2993. cat > conftest.$ac_ext <<EOF
  2994. #line 3586 "configure"
  2995. #include "confdefs.h"
  2996. /* Override any gcc2 internal prototype to avoid an error. */
  2997. /* We use char because int might match the return type of a gcc2
  2998. builtin and then its argument prototype would still apply. */
  2999. char yywrap();
  3000. int main() {
  3001. yywrap()
  3002. ; return 0; }
  3003. EOF
  3004. if { (eval echo configure:3597: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  3005. rm -rf conftest*
  3006. eval "ac_cv_lib_$ac_lib_var=yes"
  3007. else
  3008. echo "configure: failed program was:" >&5
  3009. cat conftest.$ac_ext >&5
  3010. rm -rf conftest*
  3011. eval "ac_cv_lib_$ac_lib_var=no"
  3012. fi
  3013. rm -f conftest*
  3014. LIBS="$ac_save_LIBS"
  3015. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  3016. echo "$ac_t""yes" 1>&6
  3017. LEXLIB="-l$ac_lib"
  3018. else
  3019. echo "$ac_t""no" 1>&6
  3020. fi
  3021. fi
  3022. if test "$LEX" = "lex"; then
  3023. # Extract the first word of "lex", so it can be a program name with args.
  3024. set dummy lex; ac_word=$2
  3025. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3026. echo "configure:3622: checking for $ac_word" >&5
  3027. case "$LEXPATH" in
  3028. /*)
  3029. ac_cv_path_LEXPATH="$LEXPATH" # Let the user override the test with a path.
  3030. ;;
  3031. ?:/*)
  3032. ac_cv_path_LEXPATH="$LEXPATH" # Let the user override the test with a dos path.
  3033. ;;
  3034. *)
  3035. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3036. ac_dummy="$PATH"
  3037. for ac_dir in $ac_dummy; do
  3038. test -z "$ac_dir" && ac_dir=.
  3039. if test -f $ac_dir/$ac_word; then
  3040. ac_cv_path_LEXPATH="$ac_dir/$ac_word"
  3041. break
  3042. fi
  3043. done
  3044. IFS="$ac_save_ifs"
  3045. test -z "$ac_cv_path_LEXPATH" && ac_cv_path_LEXPATH="no"
  3046. ;;
  3047. esac
  3048. LEXPATH="$ac_cv_path_LEXPATH"
  3049. if test -n "$LEXPATH"; then
  3050. echo "$ac_t""$LEXPATH" 1>&6
  3051. else
  3052. echo "$ac_t""no" 1>&6
  3053. fi
  3054. if test "$LEXPATH" = "no"; then
  3055. { echo "configure: error: *** Unable to locate lex." 1>&2; exit 1; }
  3056. fi
  3057. fi
  3058. for ac_prog in 'bison -y' byacc
  3059. do
  3060. # Extract the first word of "$ac_prog", so it can be a program name with args.
  3061. set dummy $ac_prog; ac_word=$2
  3062. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3063. echo "configure:3662: checking for $ac_word" >&5
  3064. if test -n "$YACC"; then
  3065. ac_cv_prog_YACC="$YACC" # Let the user override the test.
  3066. else
  3067. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3068. ac_dummy="$PATH"
  3069. for ac_dir in $ac_dummy; do
  3070. test -z "$ac_dir" && ac_dir=.
  3071. if test -f $ac_dir/$ac_word; then
  3072. ac_cv_prog_YACC="$ac_prog"
  3073. break
  3074. fi
  3075. done
  3076. IFS="$ac_save_ifs"
  3077. fi
  3078. YACC="$ac_cv_prog_YACC"
  3079. if test -n "$YACC"; then
  3080. echo "$ac_t""$YACC" 1>&6
  3081. else
  3082. echo "$ac_t""no" 1>&6
  3083. fi
  3084. test -n "$YACC" && break
  3085. done
  3086. test -n "$YACC" || YACC="yacc"
  3087. if test "$YACC" = "yacc"; then
  3088. # Extract the first word of "yacc", so it can be a program name with args.
  3089. set dummy yacc; ac_word=$2
  3090. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3091. echo "configure:3693: checking for $ac_word" >&5
  3092. case "$YACCPATH" in
  3093. /*)
  3094. ac_cv_path_YACCPATH="$YACCPATH" # Let the user override the test with a path.
  3095. ;;
  3096. ?:/*)
  3097. ac_cv_path_YACCPATH="$YACCPATH" # Let the user override the test with a dos path.
  3098. ;;
  3099. *)
  3100. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3101. ac_dummy="$PATH"
  3102. for ac_dir in $ac_dummy; do
  3103. test -z "$ac_dir" && ac_dir=.
  3104. if test -f $ac_dir/$ac_word; then
  3105. ac_cv_path_YACCPATH="$ac_dir/$ac_word"
  3106. break
  3107. fi
  3108. done
  3109. IFS="$ac_save_ifs"
  3110. test -z "$ac_cv_path_YACCPATH" && ac_cv_path_YACCPATH="no"
  3111. ;;
  3112. esac
  3113. YACCPATH="$ac_cv_path_YACCPATH"
  3114. if test -n "$YACCPATH"; then
  3115. echo "$ac_t""$YACCPATH" 1>&6
  3116. else
  3117. echo "$ac_t""no" 1>&6
  3118. fi
  3119. if test "$YACCPATH" = "no"; then
  3120. { echo "configure: error: *** Unable to locate yacc." 1>&2; exit 1; }
  3121. fi
  3122. fi
  3123. # Extract the first word of "ranlib", so it can be a program name with args.
  3124. set dummy ranlib; ac_word=$2
  3125. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3126. echo "configure:3731: checking for $ac_word" >&5
  3127. if test -n "$RANLIB"; then
  3128. ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
  3129. else
  3130. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3131. ac_dummy="$PATH"
  3132. for ac_dir in $ac_dummy; do
  3133. test -z "$ac_dir" && ac_dir=.
  3134. if test -f $ac_dir/$ac_word; then
  3135. ac_cv_prog_RANLIB="ranlib"
  3136. break
  3137. fi
  3138. done
  3139. IFS="$ac_save_ifs"
  3140. test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
  3141. fi
  3142. RANLIB="$ac_cv_prog_RANLIB"
  3143. if test -n "$RANLIB"; then
  3144. echo "$ac_t""$RANLIB" 1>&6
  3145. else
  3146. echo "$ac_t""no" 1>&6
  3147. fi
  3148. for ac_prog in ar
  3149. do
  3150. # Extract the first word of "$ac_prog", so it can be a program name with args.
  3151. set dummy $ac_prog; ac_word=$2
  3152. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3153. echo "configure:3760: checking for $ac_word" >&5
  3154. if test -n "$AR"; then
  3155. ac_cv_prog_AR="$AR" # Let the user override the test.
  3156. else
  3157. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3158. ac_dummy="$PATH"
  3159. for ac_dir in $ac_dummy; do
  3160. test -z "$ac_dir" && ac_dir=.
  3161. if test -f $ac_dir/$ac_word; then
  3162. ac_cv_prog_AR="$ac_prog"
  3163. break
  3164. fi
  3165. done
  3166. IFS="$ac_save_ifs"
  3167. fi
  3168. AR="$ac_cv_prog_AR"
  3169. if test -n "$AR"; then
  3170. echo "$ac_t""$AR" 1>&6
  3171. else
  3172. echo "$ac_t""no" 1>&6
  3173. fi
  3174. test -n "$AR" && break
  3175. done
  3176. for ac_prog in env
  3177. do
  3178. # Extract the first word of "$ac_prog", so it can be a program name with args.
  3179. set dummy $ac_prog; ac_word=$2
  3180. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3181. echo "configure:3791: checking for $ac_word" >&5
  3182. if test -n "$ENV"; then
  3183. ac_cv_prog_ENV="$ENV" # Let the user override the test.
  3184. else
  3185. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3186. ac_dummy="$PATH"
  3187. for ac_dir in $ac_dummy; do
  3188. test -z "$ac_dir" && ac_dir=.
  3189. if test -f $ac_dir/$ac_word; then
  3190. ac_cv_prog_ENV="$ac_prog"
  3191. break
  3192. fi
  3193. done
  3194. IFS="$ac_save_ifs"
  3195. fi
  3196. ENV="$ac_cv_prog_ENV"
  3197. if test -n "$ENV"; then
  3198. echo "$ac_t""$ENV" 1>&6
  3199. else
  3200. echo "$ac_t""no" 1>&6
  3201. fi
  3202. test -n "$ENV" && break
  3203. done
  3204. # Extract the first word of "perl", so it can be a program name with args.
  3205. set dummy perl; ac_word=$2
  3206. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  3207. echo "configure:3820: checking for $ac_word" >&5
  3208. case "$PERL" in
  3209. /*)
  3210. ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
  3211. ;;
  3212. ?:/*)
  3213. ac_cv_path_PERL="$PERL" # Let the user override the test with a dos path.
  3214. ;;
  3215. *)
  3216. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3217. ac_dummy="$PATH"
  3218. for ac_dir in $ac_dummy; do
  3219. test -z "$ac_dir" && ac_dir=.
  3220. if test -f $ac_dir/$ac_word; then
  3221. ac_cv_path_PERL="$ac_dir/$ac_word"
  3222. break
  3223. fi
  3224. done
  3225. IFS="$ac_save_ifs"
  3226. test -z "$ac_cv_path_PERL" && ac_cv_path_PERL="no"
  3227. ;;
  3228. esac
  3229. PERL="$ac_cv_path_PERL"
  3230. if test -n "$PERL"; then
  3231. echo "$ac_t""$PERL" 1>&6
  3232. else
  3233. echo "$ac_t""no" 1>&6
  3234. fi
  3235. echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
  3236. echo "configure:3851: checking for ANSI C header files" >&5
  3237. cat > conftest.$ac_ext <<EOF
  3238. #line 3854 "configure"
  3239. #include "confdefs.h"
  3240. #include <stdlib.h>
  3241. #include <stdarg.h>
  3242. #include <string.h>
  3243. #include <float.h>
  3244. EOF
  3245. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3246. { (eval echo configure:3862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  3247. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  3248. if test -z "$ac_err"; then
  3249. rm -rf conftest*
  3250. ac_cv_header_stdc=yes
  3251. else
  3252. echo "$ac_err" >&5
  3253. echo "configure: failed program was:" >&5
  3254. cat conftest.$ac_ext >&5
  3255. rm -rf conftest*
  3256. ac_cv_header_stdc=no
  3257. fi
  3258. rm -f conftest*
  3259. if test $ac_cv_header_stdc = yes; then
  3260. # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  3261. cat > conftest.$ac_ext <<EOF
  3262. #line 3879 "configure"
  3263. #include "confdefs.h"
  3264. #include <string.h>
  3265. EOF
  3266. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  3267. egrep "memchr" >/dev/null 2>&1; then
  3268. :
  3269. else
  3270. rm -rf conftest*
  3271. ac_cv_header_stdc=no
  3272. fi
  3273. rm -f conftest*
  3274. fi
  3275. if test $ac_cv_header_stdc = yes; then
  3276. # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  3277. cat > conftest.$ac_ext <<EOF
  3278. #line 3897 "configure"
  3279. #include "confdefs.h"
  3280. #include <stdlib.h>
  3281. EOF
  3282. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  3283. egrep "free" >/dev/null 2>&1; then
  3284. :
  3285. else
  3286. rm -rf conftest*
  3287. ac_cv_header_stdc=no
  3288. fi
  3289. rm -f conftest*
  3290. fi
  3291. if test $ac_cv_header_stdc = yes; then
  3292. # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  3293. if test "$cross_compiling" = yes; then
  3294. :
  3295. else
  3296. cat > conftest.$ac_ext <<EOF
  3297. #line 3918 "configure"
  3298. #include "confdefs.h"
  3299. #include <ctype.h>
  3300. #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
  3301. #define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
  3302. #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
  3303. int main () { int i; for (i = 0; i < 256; i++)
  3304. if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
  3305. exit (0); }
  3306. EOF
  3307. if { (eval echo configure:3929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  3308. then
  3309. :
  3310. else
  3311. echo "configure: failed program was:" >&5
  3312. cat conftest.$ac_ext >&5
  3313. rm -fr conftest*
  3314. ac_cv_header_stdc=no
  3315. fi
  3316. rm -fr conftest*
  3317. fi
  3318. fi
  3319. echo "$ac_t""$ac_cv_header_stdc" 1>&6
  3320. if test $ac_cv_header_stdc = yes; then
  3321. cat >> confdefs.h <<\EOF
  3322. #define STDC_HEADERS 1
  3323. EOF
  3324. fi
  3325. #AC_CHECK_HEADERS(curses.h limits.h termio.h termios.h unistd.h values.h)
  3326. for ac_hdr in limits.h termio.h termios.h unistd.h values.h f2c.h g2c.h
  3327. do
  3328. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  3329. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  3330. echo "configure:3956: checking for $ac_hdr" >&5
  3331. cat > conftest.$ac_ext <<EOF
  3332. #line 3959 "configure"
  3333. #include "confdefs.h"
  3334. #include <$ac_hdr>
  3335. EOF
  3336. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3337. { (eval echo configure:3964: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  3338. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  3339. if test -z "$ac_err"; then
  3340. rm -rf conftest*
  3341. eval "ac_cv_header_$ac_safe=yes"
  3342. else
  3343. echo "$ac_err" >&5
  3344. echo "configure: failed program was:" >&5
  3345. cat conftest.$ac_ext >&5
  3346. rm -rf conftest*
  3347. eval "ac_cv_header_$ac_safe=no"
  3348. fi
  3349. rm -f conftest*
  3350. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  3351. echo "$ac_t""yes" 1>&6
  3352. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  3353. cat >> confdefs.h <<EOF
  3354. #define $ac_tr_hdr 1
  3355. EOF
  3356. else
  3357. echo "$ac_t""no" 1>&6
  3358. fi
  3359. done
  3360. for ac_hdr in sys/ioctl.h sys/mtio.h sys/resource.h sys/time.h
  3361. do
  3362. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  3363. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  3364. echo "configure:3993: checking for $ac_hdr" >&5
  3365. cat > conftest.$ac_ext <<EOF
  3366. #line 3996 "configure"
  3367. #include "confdefs.h"
  3368. #include <$ac_hdr>
  3369. EOF
  3370. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3371. { (eval echo configure:4001: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  3372. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  3373. if test -z "$ac_err"; then
  3374. rm -rf conftest*
  3375. eval "ac_cv_header_$ac_safe=yes"
  3376. else
  3377. echo "$ac_err" >&5
  3378. echo "configure: failed program was:" >&5
  3379. cat conftest.$ac_ext >&5
  3380. rm -rf conftest*
  3381. eval "ac_cv_header_$ac_safe=no"
  3382. fi
  3383. rm -f conftest*
  3384. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  3385. echo "$ac_t""yes" 1>&6
  3386. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  3387. cat >> confdefs.h <<EOF
  3388. #define $ac_tr_hdr 1
  3389. EOF
  3390. else
  3391. echo "$ac_t""no" 1>&6
  3392. fi
  3393. done
  3394. for ac_hdr in sys/timeb.h sys/types.h sys/utsname.h
  3395. do
  3396. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  3397. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  3398. echo "configure:4030: checking for $ac_hdr" >&5
  3399. cat > conftest.$ac_ext <<EOF
  3400. #line 4033 "configure"
  3401. #include "confdefs.h"
  3402. #include <$ac_hdr>
  3403. EOF
  3404. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3405. { (eval echo configure:4038: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  3406. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  3407. if test -z "$ac_err"; then
  3408. rm -rf conftest*
  3409. eval "ac_cv_header_$ac_safe=yes"
  3410. else
  3411. echo "$ac_err" >&5
  3412. echo "configure: failed program was:" >&5
  3413. cat conftest.$ac_ext >&5
  3414. rm -rf conftest*
  3415. eval "ac_cv_header_$ac_safe=no"
  3416. fi
  3417. rm -f conftest*
  3418. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  3419. echo "$ac_t""yes" 1>&6
  3420. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  3421. cat >> confdefs.h <<EOF
  3422. #define $ac_tr_hdr 1
  3423. EOF
  3424. else
  3425. echo "$ac_t""no" 1>&6
  3426. fi
  3427. done
  3428. for ac_hdr in libintl.h iconv.h
  3429. do
  3430. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  3431. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  3432. echo "configure:4067: checking for $ac_hdr" >&5
  3433. cat > conftest.$ac_ext <<EOF
  3434. #line 4070 "configure"
  3435. #include "confdefs.h"
  3436. #include <$ac_hdr>
  3437. EOF
  3438. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3439. { (eval echo configure:4075: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  3440. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  3441. if test -z "$ac_err"; then
  3442. rm -rf conftest*
  3443. eval "ac_cv_header_$ac_safe=yes"
  3444. else
  3445. echo "$ac_err" >&5
  3446. echo "configure: failed program was:" >&5
  3447. cat conftest.$ac_ext >&5
  3448. rm -rf conftest*
  3449. eval "ac_cv_header_$ac_safe=no"
  3450. fi
  3451. rm -f conftest*
  3452. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  3453. echo "$ac_t""yes" 1>&6
  3454. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  3455. cat >> confdefs.h <<EOF
  3456. #define $ac_tr_hdr 1
  3457. EOF
  3458. else
  3459. echo "$ac_t""no" 1>&6
  3460. fi
  3461. done
  3462. for ac_hdr in langinfo.h
  3463. do
  3464. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  3465. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  3466. echo "configure:4104: checking for $ac_hdr" >&5
  3467. cat > conftest.$ac_ext <<EOF
  3468. #line 4107 "configure"
  3469. #include "confdefs.h"
  3470. #include <$ac_hdr>
  3471. EOF
  3472. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  3473. { (eval echo configure:4112: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  3474. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  3475. if test -z "$ac_err"; then
  3476. rm -rf conftest*
  3477. eval "ac_cv_header_$ac_safe=yes"
  3478. else
  3479. echo "$ac_err" >&5
  3480. echo "configure: failed program was:" >&5
  3481. cat conftest.$ac_ext >&5
  3482. rm -rf conftest*
  3483. eval "ac_cv_header_$ac_safe=no"
  3484. fi
  3485. rm -f conftest*
  3486. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  3487. echo "$ac_t""yes" 1>&6
  3488. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  3489. cat >> confdefs.h <<EOF
  3490. #define $ac_tr_hdr 1
  3491. EOF
  3492. else
  3493. echo "$ac_t""no" 1>&6
  3494. fi
  3495. done
  3496. echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
  3497. echo "configure:4138: checking whether time.h and sys/time.h may both be included" >&5
  3498. cat > conftest.$ac_ext <<EOF
  3499. #line 4141 "configure"
  3500. #include "confdefs.h"
  3501. #include <sys/types.h>
  3502. #include <sys/time.h>
  3503. #include <time.h>
  3504. int main() {
  3505. struct tm *tp;
  3506. ; return 0; }
  3507. EOF
  3508. if { (eval echo configure:4150: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  3509. rm -rf conftest*
  3510. ac_cv_header_time=yes
  3511. else
  3512. echo "configure: failed program was:" >&5
  3513. cat conftest.$ac_ext >&5
  3514. rm -rf conftest*
  3515. ac_cv_header_time=no
  3516. fi
  3517. rm -f conftest*
  3518. echo "$ac_t""$ac_cv_header_time" 1>&6
  3519. if test $ac_cv_header_time = yes; then
  3520. cat >> confdefs.h <<\EOF
  3521. #define TIME_WITH_SYS_TIME 1
  3522. EOF
  3523. fi
  3524. echo $ac_n "checking for off_t""... $ac_c" 1>&6
  3525. echo "configure:4170: checking for off_t" >&5
  3526. cat > conftest.$ac_ext <<EOF
  3527. #line 4173 "configure"
  3528. #include "confdefs.h"
  3529. #include <sys/types.h>
  3530. #if STDC_HEADERS
  3531. #include <stdlib.h>
  3532. #include <stddef.h>
  3533. #endif
  3534. EOF
  3535. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  3536. egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
  3537. rm -rf conftest*
  3538. ac_cv_type_off_t=yes
  3539. else
  3540. rm -rf conftest*
  3541. ac_cv_type_off_t=no
  3542. fi
  3543. rm -f conftest*
  3544. echo "$ac_t""$ac_cv_type_off_t" 1>&6
  3545. if test $ac_cv_type_off_t = no; then
  3546. cat >> confdefs.h <<\EOF
  3547. #define off_t long
  3548. EOF
  3549. fi
  3550. echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
  3551. echo "configure:4200: checking for uid_t in sys/types.h" >&5
  3552. cat > conftest.$ac_ext <<EOF
  3553. #line 4203 "configure"
  3554. #include "confdefs.h"
  3555. #include <sys/types.h>
  3556. EOF
  3557. if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  3558. egrep "uid_t" >/dev/null 2>&1; then
  3559. rm -rf conftest*
  3560. ac_cv_type_uid_t=yes
  3561. else
  3562. rm -rf conftest*
  3563. ac_cv_type_uid_t=no
  3564. fi
  3565. rm -f conftest*
  3566. echo "$ac_t""$ac_cv_type_uid_t" 1>&6
  3567. if test $ac_cv_type_uid_t = no; then
  3568. cat >> confdefs.h <<\EOF
  3569. #define uid_t int
  3570. EOF
  3571. cat >> confdefs.h <<\EOF
  3572. #define gid_t int
  3573. EOF
  3574. fi
  3575. echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
  3576. echo "configure:4231: checking return type of signal handlers" >&5
  3577. cat > conftest.$ac_ext <<EOF
  3578. #line 4234 "configure"
  3579. #include "confdefs.h"
  3580. #include <sys/types.h>
  3581. #include <signal.h>
  3582. #ifdef signal
  3583. #undef signal
  3584. #endif
  3585. #ifdef __cplusplus
  3586. extern "C" void (*signal (int, void (*)(int)))(int);
  3587. #else
  3588. void (*signal ()) ();
  3589. #endif
  3590. int main() {
  3591. int i;
  3592. ; return 0; }
  3593. EOF
  3594. if { (eval echo configure:4251: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  3595. rm -rf conftest*
  3596. ac_cv_type_signal=void
  3597. else
  3598. echo "configure: failed program was:" >&5
  3599. cat conftest.$ac_ext >&5
  3600. rm -rf conftest*
  3601. ac_cv_type_signal=int
  3602. fi
  3603. rm -f conftest*
  3604. echo "$ac_t""$ac_cv_type_signal" 1>&6
  3605. cat >> confdefs.h <<EOF
  3606. #define RETSIGTYPE $ac_cv_type_signal
  3607. EOF
  3608. echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
  3609. echo "configure:4269: checking for Cygwin environment" >&5
  3610. cat > conftest.$ac_ext <<EOF
  3611. #line 4272 "configure"
  3612. #include "confdefs.h"
  3613. int main() {
  3614. #ifndef __CYGWIN__
  3615. #define __CYGWIN__ __CYGWIN32__
  3616. #endif
  3617. return __CYGWIN__;
  3618. ; return 0; }
  3619. EOF
  3620. if { (eval echo configure:4283: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  3621. rm -rf conftest*
  3622. ac_cv_cygwin=yes
  3623. else
  3624. echo "configure: failed program was:" >&5
  3625. cat conftest.$ac_ext >&5
  3626. rm -rf conftest*
  3627. ac_cv_cygwin=no
  3628. fi
  3629. rm -f conftest*
  3630. rm -f conftest*
  3631. echo "$ac_t""$ac_cv_cygwin" 1>&6
  3632. CYGWIN=
  3633. test "$ac_cv_cygwin" = yes && CYGWIN=yes
  3634. for ac_func in ftime gethostname gettimeofday lseek nice time uname
  3635. do
  3636. echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
  3637. echo "configure:4301: checking for $ac_func" >&5
  3638. cat > conftest.$ac_ext <<EOF
  3639. #line 4304 "configure"
  3640. #include "confdefs.h"
  3641. /* System header to define __stub macros and hopefully few prototypes,
  3642. which can conflict with char $ac_func(); below. */
  3643. #include <assert.h>
  3644. /* Override any gcc2 internal prototype to avoid an error. */
  3645. /* We use char because int might match the return type of a gcc2
  3646. builtin and then its argument prototype would still apply. */
  3647. char $ac_func();
  3648. int main() {
  3649. /* The GNU C library defines this for functions which it implements
  3650. to always fail with ENOSYS. Some functions are actually named
  3651. something starting with __ and the normal name is an alias. */
  3652. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  3653. choke me
  3654. #else
  3655. $ac_func();
  3656. #endif
  3657. ; return 0; }
  3658. EOF
  3659. if { (eval echo configure:4327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  3660. rm -rf conftest*
  3661. eval "ac_cv_func_$ac_func=yes"
  3662. else
  3663. echo "configure: failed program was:" >&5
  3664. cat conftest.$ac_ext >&5
  3665. rm -rf conftest*
  3666. eval "ac_cv_func_$ac_func=no"
  3667. fi
  3668. rm -f conftest*
  3669. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  3670. echo "$ac_t""yes" 1>&6
  3671. ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  3672. cat >> confdefs.h <<EOF
  3673. #define $ac_tr_func 1
  3674. EOF
  3675. else
  3676. echo "$ac_t""no" 1>&6
  3677. fi
  3678. done
  3679. for ac_func in seteuid setpriority setreuid setruid
  3680. do
  3681. echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
  3682. echo "configure:4353: checking for $ac_func" >&5
  3683. cat > conftest.$ac_ext <<EOF
  3684. #line 4356 "configure"
  3685. #include "confdefs.h"
  3686. /* System header to define __stub macros and hopefully few prototypes,
  3687. which can conflict with char $ac_func(); below. */
  3688. #include <assert.h>
  3689. /* Override any gcc2 internal prototype to avoid an error. */
  3690. /* We use char because int might match the return type of a gcc2
  3691. builtin and then its argument prototype would still apply. */
  3692. char $ac_func();
  3693. int main() {
  3694. /* The GNU C library defines this for functions which it implements
  3695. to always fail with ENOSYS. Some functions are actually named
  3696. something starting with __ and the normal name is an alias. */
  3697. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  3698. choke me
  3699. #else
  3700. $ac_func();
  3701. #endif
  3702. ; return 0; }
  3703. EOF
  3704. if { (eval echo configure:4379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  3705. rm -rf conftest*
  3706. eval "ac_cv_func_$ac_func=yes"
  3707. else
  3708. echo "configure: failed program was:" >&5
  3709. cat conftest.$ac_ext >&5
  3710. rm -rf conftest*
  3711. eval "ac_cv_func_$ac_func=no"
  3712. fi
  3713. rm -f conftest*
  3714. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  3715. echo "$ac_t""yes" 1>&6
  3716. ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  3717. cat >> confdefs.h <<EOF
  3718. #define $ac_tr_func 1
  3719. EOF
  3720. else
  3721. echo "$ac_t""no" 1>&6
  3722. fi
  3723. done
  3724. for ac_func in drand48
  3725. do
  3726. echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
  3727. echo "configure:4405: checking for $ac_func" >&5
  3728. cat > conftest.$ac_ext <<EOF
  3729. #line 4408 "configure"
  3730. #include "confdefs.h"
  3731. /* System header to define __stub macros and hopefully few prototypes,
  3732. which can conflict with char $ac_func(); below. */
  3733. #include <assert.h>
  3734. /* Override any gcc2 internal prototype to avoid an error. */
  3735. /* We use char because int might match the return type of a gcc2
  3736. builtin and then its argument prototype would still apply. */
  3737. char $ac_func();
  3738. int main() {
  3739. /* The GNU C library defines this for functions which it implements
  3740. to always fail with ENOSYS. Some functions are actually named
  3741. something starting with __ and the normal name is an alias. */
  3742. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  3743. choke me
  3744. #else
  3745. $ac_func();
  3746. #endif
  3747. ; return 0; }
  3748. EOF
  3749. if { (eval echo configure:4431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  3750. rm -rf conftest*
  3751. eval "ac_cv_func_$ac_func=yes"
  3752. else
  3753. echo "configure: failed program was:" >&5
  3754. cat conftest.$ac_ext >&5
  3755. rm -rf conftest*
  3756. eval "ac_cv_func_$ac_func=no"
  3757. fi
  3758. rm -f conftest*
  3759. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  3760. echo "$ac_t""yes" 1>&6
  3761. ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  3762. cat >> confdefs.h <<EOF
  3763. #define $ac_tr_func 1
  3764. EOF
  3765. else
  3766. echo "$ac_t""no" 1>&6
  3767. fi
  3768. done
  3769. for ac_func in putenv setenv
  3770. do
  3771. echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
  3772. echo "configure:4457: checking for $ac_func" >&5
  3773. cat > conftest.$ac_ext <<EOF
  3774. #line 4460 "configure"
  3775. #include "confdefs.h"
  3776. /* System header to define __stub macros and hopefully few prototypes,
  3777. which can conflict with char $ac_func(); below. */
  3778. #include <assert.h>
  3779. /* Override any gcc2 internal prototype to avoid an error. */
  3780. /* We use char because int might match the return type of a gcc2
  3781. builtin and then its argument prototype would still apply. */
  3782. char $ac_func();
  3783. int main() {
  3784. /* The GNU C library defines this for functions which it implements
  3785. to always fail with ENOSYS. Some functions are actually named
  3786. something starting with __ and the normal name is an alias. */
  3787. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  3788. choke me
  3789. #else
  3790. $ac_func();
  3791. #endif
  3792. ; return 0; }
  3793. EOF
  3794. if { (eval echo configure:4483: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  3795. rm -rf conftest*
  3796. eval "ac_cv_func_$ac_func=yes"
  3797. else
  3798. echo "configure: failed program was:" >&5
  3799. cat conftest.$ac_ext >&5
  3800. rm -rf conftest*
  3801. eval "ac_cv_func_$ac_func=no"
  3802. fi
  3803. rm -f conftest*
  3804. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  3805. echo "$ac_t""yes" 1>&6
  3806. ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  3807. cat >> confdefs.h <<EOF
  3808. #define $ac_tr_func 1
  3809. EOF
  3810. else
  3811. echo "$ac_t""no" 1>&6
  3812. fi
  3813. done
  3814. for ac_func in nanosleep
  3815. do
  3816. echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
  3817. echo "configure:4509: checking for $ac_func" >&5
  3818. cat > conftest.$ac_ext <<EOF
  3819. #line 4512 "configure"
  3820. #include "confdefs.h"
  3821. /* System header to define __stub macros and hopefully few prototypes,
  3822. which can conflict with char $ac_func(); below. */
  3823. #include <assert.h>
  3824. /* Override any gcc2 internal prototype to avoid an error. */
  3825. /* We use char because int might match the return type of a gcc2
  3826. builtin and then its argument prototype would still apply. */
  3827. char $ac_func();
  3828. int main() {
  3829. /* The GNU C library defines this for functions which it implements
  3830. to always fail with ENOSYS. Some functions are actually named
  3831. something starting with __ and the normal name is an alias. */
  3832. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  3833. choke me
  3834. #else
  3835. $ac_func();
  3836. #endif
  3837. ; return 0; }
  3838. EOF
  3839. if { (eval echo configure:4535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  3840. rm -rf conftest*
  3841. eval "ac_cv_func_$ac_func=yes"
  3842. else
  3843. echo "configure: failed program was:" >&5
  3844. cat conftest.$ac_ext >&5
  3845. rm -rf conftest*
  3846. eval "ac_cv_func_$ac_func=no"
  3847. fi
  3848. rm -f conftest*
  3849. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  3850. echo "$ac_t""yes" 1>&6
  3851. ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  3852. cat >> confdefs.h <<EOF
  3853. #define $ac_tr_func 1
  3854. EOF
  3855. else
  3856. echo "$ac_t""no" 1>&6
  3857. fi
  3858. done
  3859. if test "$cross_compiling" != "yes" ; then
  3860. echo $ac_n "checking whether setpgrp takes no argument""... $ac_c" 1>&6
  3861. echo "configure:4560: checking whether setpgrp takes no argument" >&5
  3862. if test "$cross_compiling" = yes; then
  3863. { echo "configure: error: cannot check setpgrp if cross compiling" 1>&2; exit 1; }
  3864. else
  3865. cat > conftest.$ac_ext <<EOF
  3866. #line 4566 "configure"
  3867. #include "confdefs.h"
  3868. #ifdef HAVE_UNISTD_H
  3869. #include <unistd.h>
  3870. #endif
  3871. /*
  3872. * If this system has a BSD-style setpgrp, which takes arguments, exit
  3873. * successfully.
  3874. */
  3875. main()
  3876. {
  3877. if (setpgrp(1,1) == -1)
  3878. exit(0);
  3879. else
  3880. exit(1);
  3881. }
  3882. EOF
  3883. if { (eval echo configure:4586: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  3884. then
  3885. ac_cv_func_setpgrp_void=no
  3886. else
  3887. echo "configure: failed program was:" >&5
  3888. cat conftest.$ac_ext >&5
  3889. rm -fr conftest*
  3890. ac_cv_func_setpgrp_void=yes
  3891. fi
  3892. rm -fr conftest*
  3893. fi
  3894. echo "$ac_t""$ac_cv_func_setpgrp_void" 1>&6
  3895. if test $ac_cv_func_setpgrp_void = yes; then
  3896. cat >> confdefs.h <<\EOF
  3897. #define SETPGRP_VOID 1
  3898. EOF
  3899. fi
  3900. else
  3901. CROSS_COMPILING=1
  3902. fi
  3903. echo $ac_n "checking for long long int""... $ac_c" 1>&6
  3904. echo "configure:4614: checking for long long int" >&5
  3905. cat > conftest.$ac_ext <<EOF
  3906. #line 4616 "configure"
  3907. #include "confdefs.h"
  3908. int main() {
  3909. long long int x;
  3910. ; return 0; }
  3911. EOF
  3912. if { (eval echo configure:4623: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  3913. rm -rf conftest*
  3914. echo "$ac_t""yes" 1>&6
  3915. cat >> confdefs.h <<\EOF
  3916. #define HAVE_LONG_LONG_INT 1
  3917. EOF
  3918. else
  3919. echo "configure: failed program was:" >&5
  3920. cat conftest.$ac_ext >&5
  3921. rm -rf conftest*
  3922. echo "$ac_t""no" 1>&6
  3923. fi
  3924. rm -f conftest*
  3925. echo $ac_n "checking for W11""... $ac_c" 1>&6
  3926. echo "configure:4643: checking for W11" >&5
  3927. case "$enable_w11" in
  3928. yes|no) echo "$ac_t"""$enable_w11"" 1>&6 ;;
  3929. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  3930. esac
  3931. USE_X11=
  3932. USE_W11=
  3933. XLIB=
  3934. XTLIB=
  3935. if test "$enable_w11" = "yes" ; then
  3936. X_CFLAGS=-I${SRCDIR}/display/drivers/windows/libW11
  3937. X_LIBS='-L$(LIBDIR)'
  3938. USE_W11="1"
  3939. USE_X11="1"
  3940. XLIB=-lX11
  3941. CFLAGS="$CFLAGS -D__W98__"
  3942. else
  3943. # If we find X, set shell vars x_includes and x_libraries to the
  3944. # paths, otherwise set no_x=yes.
  3945. # Uses ac_ vars as temps to allow command line to override cache and checks.
  3946. # --without-x overrides everything else, but does not touch the cache.
  3947. echo $ac_n "checking for X""... $ac_c" 1>&6
  3948. echo "configure:4671: checking for X" >&5
  3949. # Check whether --with-x or --without-x was given.
  3950. if test "${with_x+set}" = set; then
  3951. withval="$with_x"
  3952. :
  3953. fi
  3954. # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
  3955. if test "x$with_x" = xno; then
  3956. # The user explicitly disabled X.
  3957. have_x=disabled
  3958. else
  3959. if test "x$x_includes" != xNONE && test "x$x_libraries" != xNONE; then
  3960. # Both variables are already set.
  3961. have_x=yes
  3962. else
  3963. # One or both of the vars are not set, and there is no cached value.
  3964. ac_x_includes=NO ac_x_libraries=NO
  3965. rm -fr conftestdir
  3966. if mkdir conftestdir; then
  3967. cd conftestdir
  3968. # Make sure to not put "make" in the Imakefile rules, since we grep it out.
  3969. cat > Imakefile <<'EOF'
  3970. acfindx:
  3971. @echo 'ac_im_incroot="${INCROOT}"; ac_im_usrlibdir="${USRLIBDIR}"; ac_im_libdir="${LIBDIR}"'
  3972. EOF
  3973. if (xmkmf) >/dev/null 2>/dev/null && test -f Makefile; then
  3974. # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
  3975. eval `${MAKE-make} acfindx 2>/dev/null | grep -v make`
  3976. # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
  3977. for ac_extension in a so sl; do
  3978. if test ! -f $ac_im_usrlibdir/libX11.$ac_extension &&
  3979. test -f $ac_im_libdir/libX11.$ac_extension; then
  3980. ac_im_usrlibdir=$ac_im_libdir; break
  3981. fi
  3982. done
  3983. # Screen out bogus values from the imake configuration. They are
  3984. # bogus both because they are the default anyway, and because
  3985. # using them would break gcc on systems where it needs fixed includes.
  3986. case "$ac_im_incroot" in
  3987. /usr/include) ;;
  3988. *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes="$ac_im_incroot" ;;
  3989. esac
  3990. case "$ac_im_usrlibdir" in
  3991. /usr/lib | /lib) ;;
  3992. *) test -d "$ac_im_usrlibdir" && ac_x_libraries="$ac_im_usrlibdir" ;;
  3993. esac
  3994. fi
  3995. cd ..
  3996. rm -fr conftestdir
  3997. fi
  3998. if test "$ac_x_includes" = NO; then
  3999. # Guess where to find include files, by looking for this one X11 .h file.
  4000. test -z "$x_direct_test_include" && x_direct_test_include=X11/Intrinsic.h
  4001. # First, try using that file with no special directory specified.
  4002. cat > conftest.$ac_ext <<EOF
  4003. #line 4731 "configure"
  4004. #include "confdefs.h"
  4005. #include <$x_direct_test_include>
  4006. EOF
  4007. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  4008. { (eval echo configure:4736: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  4009. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  4010. if test -z "$ac_err"; then
  4011. rm -rf conftest*
  4012. # We can compile using X headers with no special include directory.
  4013. ac_x_includes=
  4014. else
  4015. echo "$ac_err" >&5
  4016. echo "configure: failed program was:" >&5
  4017. cat conftest.$ac_ext >&5
  4018. rm -rf conftest*
  4019. # Look for the header file in a standard set of common directories.
  4020. # Check X11 before X11Rn because it is often a symlink to the current release.
  4021. for ac_dir in \
  4022. /usr/X11/include \
  4023. /usr/X11R6/include \
  4024. /usr/X11R5/include \
  4025. /usr/X11R4/include \
  4026. \
  4027. /usr/include/X11 \
  4028. /usr/include/X11R6 \
  4029. /usr/include/X11R5 \
  4030. /usr/include/X11R4 \
  4031. \
  4032. /usr/local/X11/include \
  4033. /usr/local/X11R6/include \
  4034. /usr/local/X11R5/include \
  4035. /usr/local/X11R4/include \
  4036. \
  4037. /usr/local/include/X11 \
  4038. /usr/local/include/X11R6 \
  4039. /usr/local/include/X11R5 \
  4040. /usr/local/include/X11R4 \
  4041. \
  4042. /usr/X386/include \
  4043. /usr/x386/include \
  4044. /usr/XFree86/include/X11 \
  4045. \
  4046. /usr/include \
  4047. /usr/local/include \
  4048. /usr/unsupported/include \
  4049. /usr/athena/include \
  4050. /usr/local/x11r5/include \
  4051. /usr/lpp/Xamples/include \
  4052. \
  4053. /usr/openwin/include \
  4054. /usr/openwin/share/include \
  4055. ; \
  4056. do
  4057. if test -r "$ac_dir/$x_direct_test_include"; then
  4058. ac_x_includes=$ac_dir
  4059. break
  4060. fi
  4061. done
  4062. fi
  4063. rm -f conftest*
  4064. fi # $ac_x_includes = NO
  4065. if test "$ac_x_libraries" = NO; then
  4066. # Check for the libraries.
  4067. test -z "$x_direct_test_library" && x_direct_test_library=Xt
  4068. test -z "$x_direct_test_function" && x_direct_test_function=XtMalloc
  4069. # See if we find them without any special options.
  4070. # Don't add to $LIBS permanently.
  4071. ac_save_LIBS="$LIBS"
  4072. LIBS="-l$x_direct_test_library $LIBS"
  4073. cat > conftest.$ac_ext <<EOF
  4074. #line 4805 "configure"
  4075. #include "confdefs.h"
  4076. int main() {
  4077. ${x_direct_test_function}()
  4078. ; return 0; }
  4079. EOF
  4080. if { (eval echo configure:4812: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4081. rm -rf conftest*
  4082. LIBS="$ac_save_LIBS"
  4083. # We can link X programs with no special library path.
  4084. ac_x_libraries=
  4085. else
  4086. echo "configure: failed program was:" >&5
  4087. cat conftest.$ac_ext >&5
  4088. rm -rf conftest*
  4089. LIBS="$ac_save_LIBS"
  4090. # First see if replacing the include by lib works.
  4091. # Check X11 before X11Rn because it is often a symlink to the current release.
  4092. for ac_dir in `echo "$ac_x_includes" | sed s/include/lib/` \
  4093. /usr/X11/lib \
  4094. /usr/X11R6/lib \
  4095. /usr/X11R5/lib \
  4096. /usr/X11R4/lib \
  4097. \
  4098. /usr/lib/X11 \
  4099. /usr/lib/X11R6 \
  4100. /usr/lib/X11R5 \
  4101. /usr/lib/X11R4 \
  4102. \
  4103. /usr/local/X11/lib \
  4104. /usr/local/X11R6/lib \
  4105. /usr/local/X11R5/lib \
  4106. /usr/local/X11R4/lib \
  4107. \
  4108. /usr/local/lib/X11 \
  4109. /usr/local/lib/X11R6 \
  4110. /usr/local/lib/X11R5 \
  4111. /usr/local/lib/X11R4 \
  4112. \
  4113. /usr/X386/lib \
  4114. /usr/x386/lib \
  4115. /usr/XFree86/lib/X11 \
  4116. \
  4117. /usr/lib \
  4118. /usr/local/lib \
  4119. /usr/unsupported/lib \
  4120. /usr/athena/lib \
  4121. /usr/local/x11r5/lib \
  4122. /usr/lpp/Xamples/lib \
  4123. /lib/usr/lib/X11 \
  4124. \
  4125. /usr/openwin/lib \
  4126. /usr/openwin/share/lib \
  4127. ; \
  4128. do
  4129. for ac_extension in a so sl; do
  4130. if test -r $ac_dir/lib${x_direct_test_library}.$ac_extension; then
  4131. ac_x_libraries=$ac_dir
  4132. break 2
  4133. fi
  4134. done
  4135. done
  4136. fi
  4137. rm -f conftest*
  4138. fi # $ac_x_libraries = NO
  4139. if test "$ac_x_includes" = NO || test "$ac_x_libraries" = NO; then
  4140. # Didn't find X anywhere. Cache the known absence of X.
  4141. ac_cv_have_x="have_x=no"
  4142. else
  4143. # Record where we found X for the cache.
  4144. ac_cv_have_x="have_x=yes \
  4145. ac_x_includes=$ac_x_includes ac_x_libraries=$ac_x_libraries"
  4146. fi
  4147. fi
  4148. eval "$ac_cv_have_x"
  4149. fi # $with_x != no
  4150. if test "$have_x" != yes; then
  4151. echo "$ac_t""$have_x" 1>&6
  4152. no_x=yes
  4153. else
  4154. # If each of the values was on the command line, it overrides each guess.
  4155. test "x$x_includes" = xNONE && x_includes=$ac_x_includes
  4156. test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
  4157. # Update the cache value to reflect the command line values.
  4158. ac_cv_have_x="have_x=yes \
  4159. ac_x_includes=$x_includes ac_x_libraries=$x_libraries"
  4160. echo "$ac_t""libraries $x_libraries, headers $x_includes" 1>&6
  4161. fi
  4162. if test "$no_x" = yes; then
  4163. # Not all programs may use this symbol, but it does not hurt to define it.
  4164. cat >> confdefs.h <<\EOF
  4165. #define X_DISPLAY_MISSING 1
  4166. EOF
  4167. X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS=
  4168. else
  4169. if test -n "$x_includes"; then
  4170. X_CFLAGS="$X_CFLAGS -I$x_includes"
  4171. fi
  4172. # It would also be nice to do this for all -L options, not just this one.
  4173. if test -n "$x_libraries"; then
  4174. X_LIBS="$X_LIBS -L$x_libraries"
  4175. # For Solaris; some versions of Sun CC require a space after -R and
  4176. # others require no space. Words are not sufficient . . . .
  4177. case "`(uname -sr) 2>/dev/null`" in
  4178. "SunOS 5"*)
  4179. echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
  4180. echo "configure:4917: checking whether -R must be followed by a space" >&5
  4181. ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
  4182. cat > conftest.$ac_ext <<EOF
  4183. #line 4920 "configure"
  4184. #include "confdefs.h"
  4185. int main() {
  4186. ; return 0; }
  4187. EOF
  4188. if { (eval echo configure:4927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4189. rm -rf conftest*
  4190. ac_R_nospace=yes
  4191. else
  4192. echo "configure: failed program was:" >&5
  4193. cat conftest.$ac_ext >&5
  4194. rm -rf conftest*
  4195. ac_R_nospace=no
  4196. fi
  4197. rm -f conftest*
  4198. if test $ac_R_nospace = yes; then
  4199. echo "$ac_t""no" 1>&6
  4200. X_LIBS="$X_LIBS -R$x_libraries"
  4201. else
  4202. LIBS="$ac_xsave_LIBS -R $x_libraries"
  4203. cat > conftest.$ac_ext <<EOF
  4204. #line 4943 "configure"
  4205. #include "confdefs.h"
  4206. int main() {
  4207. ; return 0; }
  4208. EOF
  4209. if { (eval echo configure:4950: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4210. rm -rf conftest*
  4211. ac_R_space=yes
  4212. else
  4213. echo "configure: failed program was:" >&5
  4214. cat conftest.$ac_ext >&5
  4215. rm -rf conftest*
  4216. ac_R_space=no
  4217. fi
  4218. rm -f conftest*
  4219. if test $ac_R_space = yes; then
  4220. echo "$ac_t""yes" 1>&6
  4221. X_LIBS="$X_LIBS -R $x_libraries"
  4222. else
  4223. echo "$ac_t""neither works" 1>&6
  4224. fi
  4225. fi
  4226. LIBS="$ac_xsave_LIBS"
  4227. esac
  4228. fi
  4229. # Check for system-dependent libraries X programs must link with.
  4230. # Do this before checking for the system-independent R6 libraries
  4231. # (-lICE), since we may need -lsocket or whatever for X linking.
  4232. if test "$ISC" = yes; then
  4233. X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet"
  4234. else
  4235. # Martyn.Johnson@cl.cam.ac.uk says this is needed for Ultrix, if the X
  4236. # libraries were built with DECnet support. And karl@cs.umb.edu says
  4237. # the Alpha needs dnet_stub (dnet does not exist).
  4238. echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
  4239. echo "configure:4982: checking for dnet_ntoa in -ldnet" >&5
  4240. ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
  4241. ac_save_LIBS="$LIBS"
  4242. LIBS="-ldnet $LIBS"
  4243. cat > conftest.$ac_ext <<EOF
  4244. #line 4988 "configure"
  4245. #include "confdefs.h"
  4246. /* Override any gcc2 internal prototype to avoid an error. */
  4247. /* We use char because int might match the return type of a gcc2
  4248. builtin and then its argument prototype would still apply. */
  4249. char dnet_ntoa();
  4250. int main() {
  4251. dnet_ntoa()
  4252. ; return 0; }
  4253. EOF
  4254. if { (eval echo configure:4999: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4255. rm -rf conftest*
  4256. eval "ac_cv_lib_$ac_lib_var=yes"
  4257. else
  4258. echo "configure: failed program was:" >&5
  4259. cat conftest.$ac_ext >&5
  4260. rm -rf conftest*
  4261. eval "ac_cv_lib_$ac_lib_var=no"
  4262. fi
  4263. rm -f conftest*
  4264. LIBS="$ac_save_LIBS"
  4265. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4266. echo "$ac_t""yes" 1>&6
  4267. X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet"
  4268. else
  4269. echo "$ac_t""no" 1>&6
  4270. fi
  4271. if test $ac_cv_lib_dnet_dnet_ntoa = no; then
  4272. echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
  4273. echo "configure:5020: checking for dnet_ntoa in -ldnet_stub" >&5
  4274. ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
  4275. ac_save_LIBS="$LIBS"
  4276. LIBS="-ldnet_stub $LIBS"
  4277. cat > conftest.$ac_ext <<EOF
  4278. #line 5026 "configure"
  4279. #include "confdefs.h"
  4280. /* Override any gcc2 internal prototype to avoid an error. */
  4281. /* We use char because int might match the return type of a gcc2
  4282. builtin and then its argument prototype would still apply. */
  4283. char dnet_ntoa();
  4284. int main() {
  4285. dnet_ntoa()
  4286. ; return 0; }
  4287. EOF
  4288. if { (eval echo configure:5037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4289. rm -rf conftest*
  4290. eval "ac_cv_lib_$ac_lib_var=yes"
  4291. else
  4292. echo "configure: failed program was:" >&5
  4293. cat conftest.$ac_ext >&5
  4294. rm -rf conftest*
  4295. eval "ac_cv_lib_$ac_lib_var=no"
  4296. fi
  4297. rm -f conftest*
  4298. LIBS="$ac_save_LIBS"
  4299. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4300. echo "$ac_t""yes" 1>&6
  4301. X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub"
  4302. else
  4303. echo "$ac_t""no" 1>&6
  4304. fi
  4305. fi
  4306. # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT,
  4307. # to get the SysV transport functions.
  4308. # chad@anasazi.com says the Pyramis MIS-ES running DC/OSx (SVR4)
  4309. # needs -lnsl.
  4310. # The nsl library prevents programs from opening the X display
  4311. # on Irix 5.2, according to dickey@clark.net.
  4312. echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
  4313. echo "configure:5065: checking for gethostbyname" >&5
  4314. cat > conftest.$ac_ext <<EOF
  4315. #line 5068 "configure"
  4316. #include "confdefs.h"
  4317. /* System header to define __stub macros and hopefully few prototypes,
  4318. which can conflict with char gethostbyname(); below. */
  4319. #include <assert.h>
  4320. /* Override any gcc2 internal prototype to avoid an error. */
  4321. /* We use char because int might match the return type of a gcc2
  4322. builtin and then its argument prototype would still apply. */
  4323. char gethostbyname();
  4324. int main() {
  4325. /* The GNU C library defines this for functions which it implements
  4326. to always fail with ENOSYS. Some functions are actually named
  4327. something starting with __ and the normal name is an alias. */
  4328. #if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
  4329. choke me
  4330. #else
  4331. gethostbyname();
  4332. #endif
  4333. ; return 0; }
  4334. EOF
  4335. if { (eval echo configure:5091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4336. rm -rf conftest*
  4337. eval "ac_cv_func_gethostbyname=yes"
  4338. else
  4339. echo "configure: failed program was:" >&5
  4340. cat conftest.$ac_ext >&5
  4341. rm -rf conftest*
  4342. eval "ac_cv_func_gethostbyname=no"
  4343. fi
  4344. rm -f conftest*
  4345. if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
  4346. echo "$ac_t""yes" 1>&6
  4347. :
  4348. else
  4349. echo "$ac_t""no" 1>&6
  4350. fi
  4351. if test $ac_cv_func_gethostbyname = no; then
  4352. echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
  4353. echo "configure:5111: checking for gethostbyname in -lnsl" >&5
  4354. ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
  4355. ac_save_LIBS="$LIBS"
  4356. LIBS="-lnsl $LIBS"
  4357. cat > conftest.$ac_ext <<EOF
  4358. #line 5117 "configure"
  4359. #include "confdefs.h"
  4360. /* Override any gcc2 internal prototype to avoid an error. */
  4361. /* We use char because int might match the return type of a gcc2
  4362. builtin and then its argument prototype would still apply. */
  4363. char gethostbyname();
  4364. int main() {
  4365. gethostbyname()
  4366. ; return 0; }
  4367. EOF
  4368. if { (eval echo configure:5128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4369. rm -rf conftest*
  4370. eval "ac_cv_lib_$ac_lib_var=yes"
  4371. else
  4372. echo "configure: failed program was:" >&5
  4373. cat conftest.$ac_ext >&5
  4374. rm -rf conftest*
  4375. eval "ac_cv_lib_$ac_lib_var=no"
  4376. fi
  4377. rm -f conftest*
  4378. LIBS="$ac_save_LIBS"
  4379. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4380. echo "$ac_t""yes" 1>&6
  4381. X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl"
  4382. else
  4383. echo "$ac_t""no" 1>&6
  4384. fi
  4385. fi
  4386. # lieder@skyler.mavd.honeywell.com says without -lsocket,
  4387. # socket/setsockopt and other routines are undefined under SCO ODT
  4388. # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary
  4389. # on later versions), says simon@lia.di.epfl.ch: it contains
  4390. # gethostby* variants that don't use the nameserver (or something).
  4391. # -lsocket must be given before -lnsl if both are needed.
  4392. # We assume that if connect needs -lnsl, so does gethostbyname.
  4393. echo $ac_n "checking for connect""... $ac_c" 1>&6
  4394. echo "configure:5157: checking for connect" >&5
  4395. cat > conftest.$ac_ext <<EOF
  4396. #line 5160 "configure"
  4397. #include "confdefs.h"
  4398. /* System header to define __stub macros and hopefully few prototypes,
  4399. which can conflict with char connect(); below. */
  4400. #include <assert.h>
  4401. /* Override any gcc2 internal prototype to avoid an error. */
  4402. /* We use char because int might match the return type of a gcc2
  4403. builtin and then its argument prototype would still apply. */
  4404. char connect();
  4405. int main() {
  4406. /* The GNU C library defines this for functions which it implements
  4407. to always fail with ENOSYS. Some functions are actually named
  4408. something starting with __ and the normal name is an alias. */
  4409. #if defined (__stub_connect) || defined (__stub___connect)
  4410. choke me
  4411. #else
  4412. connect();
  4413. #endif
  4414. ; return 0; }
  4415. EOF
  4416. if { (eval echo configure:5183: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4417. rm -rf conftest*
  4418. eval "ac_cv_func_connect=yes"
  4419. else
  4420. echo "configure: failed program was:" >&5
  4421. cat conftest.$ac_ext >&5
  4422. rm -rf conftest*
  4423. eval "ac_cv_func_connect=no"
  4424. fi
  4425. rm -f conftest*
  4426. if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
  4427. echo "$ac_t""yes" 1>&6
  4428. :
  4429. else
  4430. echo "$ac_t""no" 1>&6
  4431. fi
  4432. if test $ac_cv_func_connect = no; then
  4433. echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
  4434. echo "configure:5203: checking for connect in -lsocket" >&5
  4435. ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
  4436. ac_save_LIBS="$LIBS"
  4437. LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
  4438. cat > conftest.$ac_ext <<EOF
  4439. #line 5209 "configure"
  4440. #include "confdefs.h"
  4441. /* Override any gcc2 internal prototype to avoid an error. */
  4442. /* We use char because int might match the return type of a gcc2
  4443. builtin and then its argument prototype would still apply. */
  4444. char connect();
  4445. int main() {
  4446. connect()
  4447. ; return 0; }
  4448. EOF
  4449. if { (eval echo configure:5220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4450. rm -rf conftest*
  4451. eval "ac_cv_lib_$ac_lib_var=yes"
  4452. else
  4453. echo "configure: failed program was:" >&5
  4454. cat conftest.$ac_ext >&5
  4455. rm -rf conftest*
  4456. eval "ac_cv_lib_$ac_lib_var=no"
  4457. fi
  4458. rm -f conftest*
  4459. LIBS="$ac_save_LIBS"
  4460. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4461. echo "$ac_t""yes" 1>&6
  4462. X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS"
  4463. else
  4464. echo "$ac_t""no" 1>&6
  4465. fi
  4466. fi
  4467. # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
  4468. echo $ac_n "checking for remove""... $ac_c" 1>&6
  4469. echo "configure:5243: checking for remove" >&5
  4470. cat > conftest.$ac_ext <<EOF
  4471. #line 5246 "configure"
  4472. #include "confdefs.h"
  4473. /* System header to define __stub macros and hopefully few prototypes,
  4474. which can conflict with char remove(); below. */
  4475. #include <assert.h>
  4476. /* Override any gcc2 internal prototype to avoid an error. */
  4477. /* We use char because int might match the return type of a gcc2
  4478. builtin and then its argument prototype would still apply. */
  4479. char remove();
  4480. int main() {
  4481. /* The GNU C library defines this for functions which it implements
  4482. to always fail with ENOSYS. Some functions are actually named
  4483. something starting with __ and the normal name is an alias. */
  4484. #if defined (__stub_remove) || defined (__stub___remove)
  4485. choke me
  4486. #else
  4487. remove();
  4488. #endif
  4489. ; return 0; }
  4490. EOF
  4491. if { (eval echo configure:5269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4492. rm -rf conftest*
  4493. eval "ac_cv_func_remove=yes"
  4494. else
  4495. echo "configure: failed program was:" >&5
  4496. cat conftest.$ac_ext >&5
  4497. rm -rf conftest*
  4498. eval "ac_cv_func_remove=no"
  4499. fi
  4500. rm -f conftest*
  4501. if eval "test \"`echo '$ac_cv_func_'remove`\" = yes"; then
  4502. echo "$ac_t""yes" 1>&6
  4503. :
  4504. else
  4505. echo "$ac_t""no" 1>&6
  4506. fi
  4507. if test $ac_cv_func_remove = no; then
  4508. echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
  4509. echo "configure:5289: checking for remove in -lposix" >&5
  4510. ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
  4511. ac_save_LIBS="$LIBS"
  4512. LIBS="-lposix $LIBS"
  4513. cat > conftest.$ac_ext <<EOF
  4514. #line 5295 "configure"
  4515. #include "confdefs.h"
  4516. /* Override any gcc2 internal prototype to avoid an error. */
  4517. /* We use char because int might match the return type of a gcc2
  4518. builtin and then its argument prototype would still apply. */
  4519. char remove();
  4520. int main() {
  4521. remove()
  4522. ; return 0; }
  4523. EOF
  4524. if { (eval echo configure:5306: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4525. rm -rf conftest*
  4526. eval "ac_cv_lib_$ac_lib_var=yes"
  4527. else
  4528. echo "configure: failed program was:" >&5
  4529. cat conftest.$ac_ext >&5
  4530. rm -rf conftest*
  4531. eval "ac_cv_lib_$ac_lib_var=no"
  4532. fi
  4533. rm -f conftest*
  4534. LIBS="$ac_save_LIBS"
  4535. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4536. echo "$ac_t""yes" 1>&6
  4537. X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix"
  4538. else
  4539. echo "$ac_t""no" 1>&6
  4540. fi
  4541. fi
  4542. # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
  4543. echo $ac_n "checking for shmat""... $ac_c" 1>&6
  4544. echo "configure:5329: checking for shmat" >&5
  4545. cat > conftest.$ac_ext <<EOF
  4546. #line 5332 "configure"
  4547. #include "confdefs.h"
  4548. /* System header to define __stub macros and hopefully few prototypes,
  4549. which can conflict with char shmat(); below. */
  4550. #include <assert.h>
  4551. /* Override any gcc2 internal prototype to avoid an error. */
  4552. /* We use char because int might match the return type of a gcc2
  4553. builtin and then its argument prototype would still apply. */
  4554. char shmat();
  4555. int main() {
  4556. /* The GNU C library defines this for functions which it implements
  4557. to always fail with ENOSYS. Some functions are actually named
  4558. something starting with __ and the normal name is an alias. */
  4559. #if defined (__stub_shmat) || defined (__stub___shmat)
  4560. choke me
  4561. #else
  4562. shmat();
  4563. #endif
  4564. ; return 0; }
  4565. EOF
  4566. if { (eval echo configure:5355: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4567. rm -rf conftest*
  4568. eval "ac_cv_func_shmat=yes"
  4569. else
  4570. echo "configure: failed program was:" >&5
  4571. cat conftest.$ac_ext >&5
  4572. rm -rf conftest*
  4573. eval "ac_cv_func_shmat=no"
  4574. fi
  4575. rm -f conftest*
  4576. if eval "test \"`echo '$ac_cv_func_'shmat`\" = yes"; then
  4577. echo "$ac_t""yes" 1>&6
  4578. :
  4579. else
  4580. echo "$ac_t""no" 1>&6
  4581. fi
  4582. if test $ac_cv_func_shmat = no; then
  4583. echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
  4584. echo "configure:5375: checking for shmat in -lipc" >&5
  4585. ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
  4586. ac_save_LIBS="$LIBS"
  4587. LIBS="-lipc $LIBS"
  4588. cat > conftest.$ac_ext <<EOF
  4589. #line 5381 "configure"
  4590. #include "confdefs.h"
  4591. /* Override any gcc2 internal prototype to avoid an error. */
  4592. /* We use char because int might match the return type of a gcc2
  4593. builtin and then its argument prototype would still apply. */
  4594. char shmat();
  4595. int main() {
  4596. shmat()
  4597. ; return 0; }
  4598. EOF
  4599. if { (eval echo configure:5392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4600. rm -rf conftest*
  4601. eval "ac_cv_lib_$ac_lib_var=yes"
  4602. else
  4603. echo "configure: failed program was:" >&5
  4604. cat conftest.$ac_ext >&5
  4605. rm -rf conftest*
  4606. eval "ac_cv_lib_$ac_lib_var=no"
  4607. fi
  4608. rm -f conftest*
  4609. LIBS="$ac_save_LIBS"
  4610. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4611. echo "$ac_t""yes" 1>&6
  4612. X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc"
  4613. else
  4614. echo "$ac_t""no" 1>&6
  4615. fi
  4616. fi
  4617. fi
  4618. # Check for libraries that X11R6 Xt/Xaw programs need.
  4619. ac_save_LDFLAGS="$LDFLAGS"
  4620. test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries"
  4621. # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to
  4622. # check for ICE first), but we must link in the order -lSM -lICE or
  4623. # we get undefined symbols. So assume we have SM if we have ICE.
  4624. # These have to be linked with before -lX11, unlike the other
  4625. # libraries we check for below, so use a different variable.
  4626. # --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
  4627. echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
  4628. echo "configure:5424: checking for IceConnectionNumber in -lICE" >&5
  4629. ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
  4630. ac_save_LIBS="$LIBS"
  4631. LIBS="-lICE $X_EXTRA_LIBS $LIBS"
  4632. cat > conftest.$ac_ext <<EOF
  4633. #line 5430 "configure"
  4634. #include "confdefs.h"
  4635. /* Override any gcc2 internal prototype to avoid an error. */
  4636. /* We use char because int might match the return type of a gcc2
  4637. builtin and then its argument prototype would still apply. */
  4638. char IceConnectionNumber();
  4639. int main() {
  4640. IceConnectionNumber()
  4641. ; return 0; }
  4642. EOF
  4643. if { (eval echo configure:5441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4644. rm -rf conftest*
  4645. eval "ac_cv_lib_$ac_lib_var=yes"
  4646. else
  4647. echo "configure: failed program was:" >&5
  4648. cat conftest.$ac_ext >&5
  4649. rm -rf conftest*
  4650. eval "ac_cv_lib_$ac_lib_var=no"
  4651. fi
  4652. rm -f conftest*
  4653. LIBS="$ac_save_LIBS"
  4654. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4655. echo "$ac_t""yes" 1>&6
  4656. X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE"
  4657. else
  4658. echo "$ac_t""no" 1>&6
  4659. fi
  4660. LDFLAGS="$ac_save_LDFLAGS"
  4661. fi
  4662. if test "$no_x" != "yes"; then
  4663. USE_X11="1"
  4664. XLIB=-lX11
  4665. XTLIB=-lXt
  4666. fi
  4667. fi
  4668. # Note that some systems (FreeBSD for example) need an extra library for
  4669. # cuserid
  4670. ac_save_libs="$LIBS"
  4671. LIBS=""
  4672. echo $ac_n "checking for library containing cuserid""... $ac_c" 1>&6
  4673. echo "configure:5481: checking for library containing cuserid" >&5
  4674. ac_func_search_save_LIBS="$LIBS"
  4675. ac_cv_search_cuserid="no"
  4676. cat > conftest.$ac_ext <<EOF
  4677. #line 5486 "configure"
  4678. #include "confdefs.h"
  4679. /* Override any gcc2 internal prototype to avoid an error. */
  4680. /* We use char because int might match the return type of a gcc2
  4681. builtin and then its argument prototype would still apply. */
  4682. char cuserid();
  4683. int main() {
  4684. cuserid()
  4685. ; return 0; }
  4686. EOF
  4687. if { (eval echo configure:5497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4688. rm -rf conftest*
  4689. ac_cv_search_cuserid="none required"
  4690. else
  4691. echo "configure: failed program was:" >&5
  4692. cat conftest.$ac_ext >&5
  4693. fi
  4694. rm -f conftest*
  4695. test "$ac_cv_search_cuserid" = "no" && for i in compat; do
  4696. LIBS="-l$i $ac_func_search_save_LIBS"
  4697. cat > conftest.$ac_ext <<EOF
  4698. #line 5508 "configure"
  4699. #include "confdefs.h"
  4700. /* Override any gcc2 internal prototype to avoid an error. */
  4701. /* We use char because int might match the return type of a gcc2
  4702. builtin and then its argument prototype would still apply. */
  4703. char cuserid();
  4704. int main() {
  4705. cuserid()
  4706. ; return 0; }
  4707. EOF
  4708. if { (eval echo configure:5519: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4709. rm -rf conftest*
  4710. ac_cv_search_cuserid="-l$i"
  4711. break
  4712. else
  4713. echo "configure: failed program was:" >&5
  4714. cat conftest.$ac_ext >&5
  4715. fi
  4716. rm -f conftest*
  4717. done
  4718. LIBS="$ac_func_search_save_LIBS"
  4719. echo "$ac_t""$ac_cv_search_cuserid" 1>&6
  4720. if test "$ac_cv_search_cuserid" != "no"; then
  4721. test "$ac_cv_search_cuserid" = "none required" || LIBS="$ac_cv_search_cuserid $LIBS"
  4722. else :
  4723. fi
  4724. DBMIEXTRALIB=$LIBS
  4725. LIBS=$ac_save_libs
  4726. # Note: -lxdr -liberty -lws2_32 is for MinGW
  4727. echo $ac_n "checking for xdrmem_create""... $ac_c" 1>&6
  4728. echo "configure:5545: checking for xdrmem_create" >&5
  4729. cat > conftest.$ac_ext <<EOF
  4730. #line 5548 "configure"
  4731. #include "confdefs.h"
  4732. /* System header to define __stub macros and hopefully few prototypes,
  4733. which can conflict with char xdrmem_create(); below. */
  4734. #include <assert.h>
  4735. /* Override any gcc2 internal prototype to avoid an error. */
  4736. /* We use char because int might match the return type of a gcc2
  4737. builtin and then its argument prototype would still apply. */
  4738. char xdrmem_create();
  4739. int main() {
  4740. /* The GNU C library defines this for functions which it implements
  4741. to always fail with ENOSYS. Some functions are actually named
  4742. something starting with __ and the normal name is an alias. */
  4743. #if defined (__stub_xdrmem_create) || defined (__stub___xdrmem_create)
  4744. choke me
  4745. #else
  4746. xdrmem_create();
  4747. #endif
  4748. ; return 0; }
  4749. EOF
  4750. if { (eval echo configure:5571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4751. rm -rf conftest*
  4752. eval "ac_cv_func_xdrmem_create=yes"
  4753. else
  4754. echo "configure: failed program was:" >&5
  4755. cat conftest.$ac_ext >&5
  4756. rm -rf conftest*
  4757. eval "ac_cv_func_xdrmem_create=no"
  4758. fi
  4759. rm -f conftest*
  4760. if eval "test \"`echo '$ac_cv_func_'xdrmem_create`\" = yes"; then
  4761. echo "$ac_t""yes" 1>&6
  4762. XDRLIB=
  4763. else
  4764. echo "$ac_t""no" 1>&6
  4765. echo $ac_n "checking for xdrmem_create in -lsun""... $ac_c" 1>&6
  4766. echo "configure:5589: checking for xdrmem_create in -lsun" >&5
  4767. ac_lib_var=`echo sun'_'xdrmem_create | sed 'y%./+-%__p_%'`
  4768. ac_save_LIBS="$LIBS"
  4769. LIBS="-lsun $LIBS"
  4770. cat > conftest.$ac_ext <<EOF
  4771. #line 5595 "configure"
  4772. #include "confdefs.h"
  4773. /* Override any gcc2 internal prototype to avoid an error. */
  4774. /* We use char because int might match the return type of a gcc2
  4775. builtin and then its argument prototype would still apply. */
  4776. char xdrmem_create();
  4777. int main() {
  4778. xdrmem_create()
  4779. ; return 0; }
  4780. EOF
  4781. if { (eval echo configure:5606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4782. rm -rf conftest*
  4783. eval "ac_cv_lib_$ac_lib_var=yes"
  4784. else
  4785. echo "configure: failed program was:" >&5
  4786. cat conftest.$ac_ext >&5
  4787. rm -rf conftest*
  4788. eval "ac_cv_lib_$ac_lib_var=no"
  4789. fi
  4790. rm -f conftest*
  4791. LIBS="$ac_save_LIBS"
  4792. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4793. echo "$ac_t""yes" 1>&6
  4794. XDRLIB=-lsun
  4795. else
  4796. echo "$ac_t""no" 1>&6
  4797. echo $ac_n "checking for xdrmem_create in -lnsl""... $ac_c" 1>&6
  4798. echo "configure:5625: checking for xdrmem_create in -lnsl" >&5
  4799. ac_lib_var=`echo nsl'_'xdrmem_create | sed 'y%./+-%__p_%'`
  4800. ac_save_LIBS="$LIBS"
  4801. LIBS="-lnsl $LIBS"
  4802. cat > conftest.$ac_ext <<EOF
  4803. #line 5631 "configure"
  4804. #include "confdefs.h"
  4805. /* Override any gcc2 internal prototype to avoid an error. */
  4806. /* We use char because int might match the return type of a gcc2
  4807. builtin and then its argument prototype would still apply. */
  4808. char xdrmem_create();
  4809. int main() {
  4810. xdrmem_create()
  4811. ; return 0; }
  4812. EOF
  4813. if { (eval echo configure:5642: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4814. rm -rf conftest*
  4815. eval "ac_cv_lib_$ac_lib_var=yes"
  4816. else
  4817. echo "configure: failed program was:" >&5
  4818. cat conftest.$ac_ext >&5
  4819. rm -rf conftest*
  4820. eval "ac_cv_lib_$ac_lib_var=no"
  4821. fi
  4822. rm -f conftest*
  4823. LIBS="$ac_save_LIBS"
  4824. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4825. echo "$ac_t""yes" 1>&6
  4826. XDRLIB=-lnsl
  4827. else
  4828. echo "$ac_t""no" 1>&6
  4829. echo $ac_n "checking for xdrmem_create in -lrpclib""... $ac_c" 1>&6
  4830. echo "configure:5661: checking for xdrmem_create in -lrpclib" >&5
  4831. ac_lib_var=`echo rpclib'_'xdrmem_create | sed 'y%./+-%__p_%'`
  4832. ac_save_LIBS="$LIBS"
  4833. LIBS="-lrpclib $LIBS"
  4834. cat > conftest.$ac_ext <<EOF
  4835. #line 5667 "configure"
  4836. #include "confdefs.h"
  4837. /* Override any gcc2 internal prototype to avoid an error. */
  4838. /* We use char because int might match the return type of a gcc2
  4839. builtin and then its argument prototype would still apply. */
  4840. char xdrmem_create();
  4841. int main() {
  4842. xdrmem_create()
  4843. ; return 0; }
  4844. EOF
  4845. if { (eval echo configure:5678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4846. rm -rf conftest*
  4847. eval "ac_cv_lib_$ac_lib_var=yes"
  4848. else
  4849. echo "configure: failed program was:" >&5
  4850. cat conftest.$ac_ext >&5
  4851. rm -rf conftest*
  4852. eval "ac_cv_lib_$ac_lib_var=no"
  4853. fi
  4854. rm -f conftest*
  4855. LIBS="$ac_save_LIBS"
  4856. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4857. echo "$ac_t""yes" 1>&6
  4858. XDRLIB=-lrpclib
  4859. else
  4860. echo "$ac_t""no" 1>&6
  4861. echo $ac_n "checking for xdrmem_create in -lxdr""... $ac_c" 1>&6
  4862. echo "configure:5697: checking for xdrmem_create in -lxdr" >&5
  4863. ac_lib_var=`echo xdr'_'xdrmem_create | sed 'y%./+-%__p_%'`
  4864. ac_save_LIBS="$LIBS"
  4865. LIBS="-lxdr -liberty -lws2_32 $LIBS"
  4866. cat > conftest.$ac_ext <<EOF
  4867. #line 5703 "configure"
  4868. #include "confdefs.h"
  4869. /* Override any gcc2 internal prototype to avoid an error. */
  4870. /* We use char because int might match the return type of a gcc2
  4871. builtin and then its argument prototype would still apply. */
  4872. char xdrmem_create();
  4873. int main() {
  4874. xdrmem_create()
  4875. ; return 0; }
  4876. EOF
  4877. if { (eval echo configure:5714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4878. rm -rf conftest*
  4879. eval "ac_cv_lib_$ac_lib_var=yes"
  4880. else
  4881. echo "configure: failed program was:" >&5
  4882. cat conftest.$ac_ext >&5
  4883. rm -rf conftest*
  4884. eval "ac_cv_lib_$ac_lib_var=no"
  4885. fi
  4886. rm -f conftest*
  4887. LIBS="$ac_save_LIBS"
  4888. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  4889. echo "$ac_t""yes" 1>&6
  4890. XDRLIB="-lxdr -liberty -lws2_32"
  4891. else
  4892. echo "$ac_t""no" 1>&6
  4893. { echo "configure: error: *** Unable to locate XDR functions." 1>&2; exit 1; }
  4894. fi
  4895. fi
  4896. fi
  4897. fi
  4898. fi
  4899. for ac_func in asprintf
  4900. do
  4901. echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
  4902. echo "configure:5748: checking for $ac_func" >&5
  4903. cat > conftest.$ac_ext <<EOF
  4904. #line 5751 "configure"
  4905. #include "confdefs.h"
  4906. /* System header to define __stub macros and hopefully few prototypes,
  4907. which can conflict with char $ac_func(); below. */
  4908. #include <assert.h>
  4909. /* Override any gcc2 internal prototype to avoid an error. */
  4910. /* We use char because int might match the return type of a gcc2
  4911. builtin and then its argument prototype would still apply. */
  4912. char $ac_func();
  4913. int main() {
  4914. /* The GNU C library defines this for functions which it implements
  4915. to always fail with ENOSYS. Some functions are actually named
  4916. something starting with __ and the normal name is an alias. */
  4917. #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
  4918. choke me
  4919. #else
  4920. $ac_func();
  4921. #endif
  4922. ; return 0; }
  4923. EOF
  4924. if { (eval echo configure:5774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4925. rm -rf conftest*
  4926. eval "ac_cv_func_$ac_func=yes"
  4927. else
  4928. echo "configure: failed program was:" >&5
  4929. cat conftest.$ac_ext >&5
  4930. rm -rf conftest*
  4931. eval "ac_cv_func_$ac_func=no"
  4932. fi
  4933. rm -f conftest*
  4934. if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  4935. echo "$ac_t""yes" 1>&6
  4936. ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  4937. cat >> confdefs.h <<EOF
  4938. #define $ac_tr_func 1
  4939. EOF
  4940. else
  4941. echo "$ac_t""no" 1>&6
  4942. fi
  4943. done
  4944. # Test if mathlib needs -lm flag or is included with libc
  4945. echo $ac_n "checking for atan""... $ac_c" 1>&6
  4946. echo "configure:5801: checking for atan" >&5
  4947. cat > conftest.$ac_ext <<EOF
  4948. #line 5804 "configure"
  4949. #include "confdefs.h"
  4950. /* System header to define __stub macros and hopefully few prototypes,
  4951. which can conflict with char atan(); below. */
  4952. #include <assert.h>
  4953. /* Override any gcc2 internal prototype to avoid an error. */
  4954. /* We use char because int might match the return type of a gcc2
  4955. builtin and then its argument prototype would still apply. */
  4956. char atan();
  4957. int main() {
  4958. /* The GNU C library defines this for functions which it implements
  4959. to always fail with ENOSYS. Some functions are actually named
  4960. something starting with __ and the normal name is an alias. */
  4961. #if defined (__stub_atan) || defined (__stub___atan)
  4962. choke me
  4963. #else
  4964. atan();
  4965. #endif
  4966. ; return 0; }
  4967. EOF
  4968. if { (eval echo configure:5827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  4969. rm -rf conftest*
  4970. eval "ac_cv_func_atan=yes"
  4971. else
  4972. echo "configure: failed program was:" >&5
  4973. cat conftest.$ac_ext >&5
  4974. rm -rf conftest*
  4975. eval "ac_cv_func_atan=no"
  4976. fi
  4977. rm -f conftest*
  4978. if eval "test \"`echo '$ac_cv_func_'atan`\" = yes"; then
  4979. echo "$ac_t""yes" 1>&6
  4980. MATHLIB=
  4981. else
  4982. echo "$ac_t""no" 1>&6
  4983. echo $ac_n "checking for atan in -lm""... $ac_c" 1>&6
  4984. echo "configure:5845: checking for atan in -lm" >&5
  4985. ac_lib_var=`echo m'_'atan | sed 'y%./+-%__p_%'`
  4986. ac_save_LIBS="$LIBS"
  4987. LIBS="-lm $LIBS"
  4988. cat > conftest.$ac_ext <<EOF
  4989. #line 5851 "configure"
  4990. #include "confdefs.h"
  4991. /* Override any gcc2 internal prototype to avoid an error. */
  4992. /* We use char because int might match the return type of a gcc2
  4993. builtin and then its argument prototype would still apply. */
  4994. char atan();
  4995. int main() {
  4996. atan()
  4997. ; return 0; }
  4998. EOF
  4999. if { (eval echo configure:5862: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5000. rm -rf conftest*
  5001. eval "ac_cv_lib_$ac_lib_var=yes"
  5002. else
  5003. echo "configure: failed program was:" >&5
  5004. cat conftest.$ac_ext >&5
  5005. rm -rf conftest*
  5006. eval "ac_cv_lib_$ac_lib_var=no"
  5007. fi
  5008. rm -f conftest*
  5009. LIBS="$ac_save_LIBS"
  5010. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5011. echo "$ac_t""yes" 1>&6
  5012. MATHLIB=-lm
  5013. else
  5014. echo "$ac_t""no" 1>&6
  5015. { echo "configure: error: *** Failed check for math library." 1>&2; exit 1; }
  5016. fi
  5017. fi
  5018. echo $ac_n "checking for dlsym""... $ac_c" 1>&6
  5019. echo "configure:5889: checking for dlsym" >&5
  5020. cat > conftest.$ac_ext <<EOF
  5021. #line 5892 "configure"
  5022. #include "confdefs.h"
  5023. /* System header to define __stub macros and hopefully few prototypes,
  5024. which can conflict with char dlsym(); below. */
  5025. #include <assert.h>
  5026. /* Override any gcc2 internal prototype to avoid an error. */
  5027. /* We use char because int might match the return type of a gcc2
  5028. builtin and then its argument prototype would still apply. */
  5029. char dlsym();
  5030. int main() {
  5031. /* The GNU C library defines this for functions which it implements
  5032. to always fail with ENOSYS. Some functions are actually named
  5033. something starting with __ and the normal name is an alias. */
  5034. #if defined (__stub_dlsym) || defined (__stub___dlsym)
  5035. choke me
  5036. #else
  5037. dlsym();
  5038. #endif
  5039. ; return 0; }
  5040. EOF
  5041. if { (eval echo configure:5915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5042. rm -rf conftest*
  5043. eval "ac_cv_func_dlsym=yes"
  5044. else
  5045. echo "configure: failed program was:" >&5
  5046. cat conftest.$ac_ext >&5
  5047. rm -rf conftest*
  5048. eval "ac_cv_func_dlsym=no"
  5049. fi
  5050. rm -f conftest*
  5051. if eval "test \"`echo '$ac_cv_func_'dlsym`\" = yes"; then
  5052. echo "$ac_t""yes" 1>&6
  5053. DLLIB=
  5054. else
  5055. echo "$ac_t""no" 1>&6
  5056. echo $ac_n "checking for dlsym in -ldl""... $ac_c" 1>&6
  5057. echo "configure:5933: checking for dlsym in -ldl" >&5
  5058. ac_lib_var=`echo dl'_'dlsym | sed 'y%./+-%__p_%'`
  5059. ac_save_LIBS="$LIBS"
  5060. LIBS="-ldl $LIBS"
  5061. cat > conftest.$ac_ext <<EOF
  5062. #line 5939 "configure"
  5063. #include "confdefs.h"
  5064. /* Override any gcc2 internal prototype to avoid an error. */
  5065. /* We use char because int might match the return type of a gcc2
  5066. builtin and then its argument prototype would still apply. */
  5067. char dlsym();
  5068. int main() {
  5069. dlsym()
  5070. ; return 0; }
  5071. EOF
  5072. if { (eval echo configure:5950: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5073. rm -rf conftest*
  5074. eval "ac_cv_lib_$ac_lib_var=yes"
  5075. else
  5076. echo "configure: failed program was:" >&5
  5077. cat conftest.$ac_ext >&5
  5078. rm -rf conftest*
  5079. eval "ac_cv_lib_$ac_lib_var=no"
  5080. fi
  5081. rm -f conftest*
  5082. LIBS="$ac_save_LIBS"
  5083. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5084. echo "$ac_t""yes" 1>&6
  5085. DLLIB=-ldl
  5086. else
  5087. echo "$ac_t""no" 1>&6
  5088. DLLIB=
  5089. fi
  5090. fi
  5091. echo $ac_n "checking for iconv""... $ac_c" 1>&6
  5092. echo "configure:5977: checking for iconv" >&5
  5093. cat > conftest.$ac_ext <<EOF
  5094. #line 5980 "configure"
  5095. #include "confdefs.h"
  5096. /* System header to define __stub macros and hopefully few prototypes,
  5097. which can conflict with char iconv(); below. */
  5098. #include <assert.h>
  5099. /* Override any gcc2 internal prototype to avoid an error. */
  5100. /* We use char because int might match the return type of a gcc2
  5101. builtin and then its argument prototype would still apply. */
  5102. char iconv();
  5103. int main() {
  5104. /* The GNU C library defines this for functions which it implements
  5105. to always fail with ENOSYS. Some functions are actually named
  5106. something starting with __ and the normal name is an alias. */
  5107. #if defined (__stub_iconv) || defined (__stub___iconv)
  5108. choke me
  5109. #else
  5110. iconv();
  5111. #endif
  5112. ; return 0; }
  5113. EOF
  5114. if { (eval echo configure:6003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5115. rm -rf conftest*
  5116. eval "ac_cv_func_iconv=yes"
  5117. else
  5118. echo "configure: failed program was:" >&5
  5119. cat conftest.$ac_ext >&5
  5120. rm -rf conftest*
  5121. eval "ac_cv_func_iconv=no"
  5122. fi
  5123. rm -f conftest*
  5124. if eval "test \"`echo '$ac_cv_func_'iconv`\" = yes"; then
  5125. echo "$ac_t""yes" 1>&6
  5126. ICONVLIB=
  5127. else
  5128. echo "$ac_t""no" 1>&6
  5129. echo $ac_n "checking for iconv in -liconv""... $ac_c" 1>&6
  5130. echo "configure:6021: checking for iconv in -liconv" >&5
  5131. ac_lib_var=`echo iconv'_'iconv | sed 'y%./+-%__p_%'`
  5132. ac_save_LIBS="$LIBS"
  5133. LIBS="-liconv $LIBS"
  5134. cat > conftest.$ac_ext <<EOF
  5135. #line 6027 "configure"
  5136. #include "confdefs.h"
  5137. /* Override any gcc2 internal prototype to avoid an error. */
  5138. /* We use char because int might match the return type of a gcc2
  5139. builtin and then its argument prototype would still apply. */
  5140. char iconv();
  5141. int main() {
  5142. iconv()
  5143. ; return 0; }
  5144. EOF
  5145. if { (eval echo configure:6038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5146. rm -rf conftest*
  5147. eval "ac_cv_lib_$ac_lib_var=yes"
  5148. else
  5149. echo "configure: failed program was:" >&5
  5150. cat conftest.$ac_ext >&5
  5151. rm -rf conftest*
  5152. eval "ac_cv_lib_$ac_lib_var=no"
  5153. fi
  5154. rm -f conftest*
  5155. LIBS="$ac_save_LIBS"
  5156. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5157. echo "$ac_t""yes" 1>&6
  5158. ICONVLIB=-liconv
  5159. else
  5160. echo "$ac_t""no" 1>&6
  5161. echo $ac_n "checking for iconv in -lgiconv""... $ac_c" 1>&6
  5162. echo "configure:6057: checking for iconv in -lgiconv" >&5
  5163. ac_lib_var=`echo giconv'_'iconv | sed 'y%./+-%__p_%'`
  5164. ac_save_LIBS="$LIBS"
  5165. LIBS="-lgiconv $LIBS"
  5166. cat > conftest.$ac_ext <<EOF
  5167. #line 6063 "configure"
  5168. #include "confdefs.h"
  5169. /* Override any gcc2 internal prototype to avoid an error. */
  5170. /* We use char because int might match the return type of a gcc2
  5171. builtin and then its argument prototype would still apply. */
  5172. char iconv();
  5173. int main() {
  5174. iconv()
  5175. ; return 0; }
  5176. EOF
  5177. if { (eval echo configure:6074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5178. rm -rf conftest*
  5179. eval "ac_cv_lib_$ac_lib_var=yes"
  5180. else
  5181. echo "configure: failed program was:" >&5
  5182. cat conftest.$ac_ext >&5
  5183. rm -rf conftest*
  5184. eval "ac_cv_lib_$ac_lib_var=no"
  5185. fi
  5186. rm -f conftest*
  5187. LIBS="$ac_save_LIBS"
  5188. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5189. echo "$ac_t""yes" 1>&6
  5190. ICONVLIB=-lgiconv
  5191. else
  5192. echo "$ac_t""no" 1>&6
  5193. echo $ac_n "checking for libiconv""... $ac_c" 1>&6
  5194. echo "configure:6093: checking for libiconv" >&5
  5195. cat > conftest.$ac_ext <<EOF
  5196. #line 6096 "configure"
  5197. #include "confdefs.h"
  5198. /* System header to define __stub macros and hopefully few prototypes,
  5199. which can conflict with char libiconv(); below. */
  5200. #include <assert.h>
  5201. /* Override any gcc2 internal prototype to avoid an error. */
  5202. /* We use char because int might match the return type of a gcc2
  5203. builtin and then its argument prototype would still apply. */
  5204. char libiconv();
  5205. int main() {
  5206. /* The GNU C library defines this for functions which it implements
  5207. to always fail with ENOSYS. Some functions are actually named
  5208. something starting with __ and the normal name is an alias. */
  5209. #if defined (__stub_libiconv) || defined (__stub___libiconv)
  5210. choke me
  5211. #else
  5212. libiconv();
  5213. #endif
  5214. ; return 0; }
  5215. EOF
  5216. if { (eval echo configure:6119: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5217. rm -rf conftest*
  5218. eval "ac_cv_func_libiconv=yes"
  5219. else
  5220. echo "configure: failed program was:" >&5
  5221. cat conftest.$ac_ext >&5
  5222. rm -rf conftest*
  5223. eval "ac_cv_func_libiconv=no"
  5224. fi
  5225. rm -f conftest*
  5226. if eval "test \"`echo '$ac_cv_func_'libiconv`\" = yes"; then
  5227. echo "$ac_t""yes" 1>&6
  5228. ICONVLIB=
  5229. else
  5230. echo "$ac_t""no" 1>&6
  5231. echo $ac_n "checking for libiconv in -liconv""... $ac_c" 1>&6
  5232. echo "configure:6137: checking for libiconv in -liconv" >&5
  5233. ac_lib_var=`echo iconv'_'libiconv | sed 'y%./+-%__p_%'`
  5234. ac_save_LIBS="$LIBS"
  5235. LIBS="-liconv $LIBS"
  5236. cat > conftest.$ac_ext <<EOF
  5237. #line 6143 "configure"
  5238. #include "confdefs.h"
  5239. /* Override any gcc2 internal prototype to avoid an error. */
  5240. /* We use char because int might match the return type of a gcc2
  5241. builtin and then its argument prototype would still apply. */
  5242. char libiconv();
  5243. int main() {
  5244. libiconv()
  5245. ; return 0; }
  5246. EOF
  5247. if { (eval echo configure:6154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5248. rm -rf conftest*
  5249. eval "ac_cv_lib_$ac_lib_var=yes"
  5250. else
  5251. echo "configure: failed program was:" >&5
  5252. cat conftest.$ac_ext >&5
  5253. rm -rf conftest*
  5254. eval "ac_cv_lib_$ac_lib_var=no"
  5255. fi
  5256. rm -f conftest*
  5257. LIBS="$ac_save_LIBS"
  5258. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5259. echo "$ac_t""yes" 1>&6
  5260. ICONVLIB=-liconv
  5261. else
  5262. echo "$ac_t""no" 1>&6
  5263. echo $ac_n "checking for libiconv in -lgiconv""... $ac_c" 1>&6
  5264. echo "configure:6173: checking for libiconv in -lgiconv" >&5
  5265. ac_lib_var=`echo giconv'_'libiconv | sed 'y%./+-%__p_%'`
  5266. ac_save_LIBS="$LIBS"
  5267. LIBS="-lgiconv $LIBS"
  5268. cat > conftest.$ac_ext <<EOF
  5269. #line 6179 "configure"
  5270. #include "confdefs.h"
  5271. /* Override any gcc2 internal prototype to avoid an error. */
  5272. /* We use char because int might match the return type of a gcc2
  5273. builtin and then its argument prototype would still apply. */
  5274. char libiconv();
  5275. int main() {
  5276. libiconv()
  5277. ; return 0; }
  5278. EOF
  5279. if { (eval echo configure:6190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5280. rm -rf conftest*
  5281. eval "ac_cv_lib_$ac_lib_var=yes"
  5282. else
  5283. echo "configure: failed program was:" >&5
  5284. cat conftest.$ac_ext >&5
  5285. rm -rf conftest*
  5286. eval "ac_cv_lib_$ac_lib_var=no"
  5287. fi
  5288. rm -f conftest*
  5289. LIBS="$ac_save_LIBS"
  5290. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5291. echo "$ac_t""yes" 1>&6
  5292. ICONVLIB=-lgiconv
  5293. else
  5294. echo "$ac_t""no" 1>&6
  5295. echo "configure: warning: *** Unable to locate iconv() function." 1>&2
  5296. ICONVLIB=
  5297. fi
  5298. fi
  5299. fi
  5300. fi
  5301. fi
  5302. fi
  5303. have_socket=1
  5304. echo $ac_n "checking for socket""... $ac_c" 1>&6
  5305. echo "configure:6227: checking for socket" >&5
  5306. cat > conftest.$ac_ext <<EOF
  5307. #line 6230 "configure"
  5308. #include "confdefs.h"
  5309. /* System header to define __stub macros and hopefully few prototypes,
  5310. which can conflict with char socket(); below. */
  5311. #include <assert.h>
  5312. /* Override any gcc2 internal prototype to avoid an error. */
  5313. /* We use char because int might match the return type of a gcc2
  5314. builtin and then its argument prototype would still apply. */
  5315. char socket();
  5316. int main() {
  5317. /* The GNU C library defines this for functions which it implements
  5318. to always fail with ENOSYS. Some functions are actually named
  5319. something starting with __ and the normal name is an alias. */
  5320. #if defined (__stub_socket) || defined (__stub___socket)
  5321. choke me
  5322. #else
  5323. socket();
  5324. #endif
  5325. ; return 0; }
  5326. EOF
  5327. if { (eval echo configure:6253: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5328. rm -rf conftest*
  5329. eval "ac_cv_func_socket=yes"
  5330. else
  5331. echo "configure: failed program was:" >&5
  5332. cat conftest.$ac_ext >&5
  5333. rm -rf conftest*
  5334. eval "ac_cv_func_socket=no"
  5335. fi
  5336. rm -f conftest*
  5337. if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
  5338. echo "$ac_t""yes" 1>&6
  5339. SOCKLIB=
  5340. else
  5341. echo "$ac_t""no" 1>&6
  5342. echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
  5343. echo "configure:6271: checking for socket in -lsocket" >&5
  5344. ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
  5345. ac_save_LIBS="$LIBS"
  5346. LIBS="-lsocket $LIBS"
  5347. cat > conftest.$ac_ext <<EOF
  5348. #line 6277 "configure"
  5349. #include "confdefs.h"
  5350. /* Override any gcc2 internal prototype to avoid an error. */
  5351. /* We use char because int might match the return type of a gcc2
  5352. builtin and then its argument prototype would still apply. */
  5353. char socket();
  5354. int main() {
  5355. socket()
  5356. ; return 0; }
  5357. EOF
  5358. if { (eval echo configure:6288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5359. rm -rf conftest*
  5360. eval "ac_cv_lib_$ac_lib_var=yes"
  5361. else
  5362. echo "configure: failed program was:" >&5
  5363. cat conftest.$ac_ext >&5
  5364. rm -rf conftest*
  5365. eval "ac_cv_lib_$ac_lib_var=no"
  5366. fi
  5367. rm -f conftest*
  5368. LIBS="$ac_save_LIBS"
  5369. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5370. echo "$ac_t""yes" 1>&6
  5371. SOCKLIB=-lsocket
  5372. else
  5373. echo "$ac_t""no" 1>&6
  5374. have_socket=0
  5375. echo "configure: warning: *** Unable to locate socket() function." 1>&2
  5376. fi
  5377. fi
  5378. if test "$have_socket" = 1 ; then
  5379. HAVE_SOCKET=1
  5380. cat >> confdefs.h <<\EOF
  5381. #define HAVE_SOCKET 1
  5382. EOF
  5383. else
  5384. HAVE_SOCKET=
  5385. fi
  5386. # Mandatory zlib dependency
  5387. ZLIBLIBPATH=
  5388. ZLIBINCPATH=
  5389. ZLIB=
  5390. # With zlib includes directory
  5391. echo $ac_n "checking for location of zlib includes""... $ac_c" 1>&6
  5392. echo "configure:6336: checking for location of zlib includes" >&5
  5393. case "$with_zlib_includes" in
  5394. y | ye | yes | n | no)
  5395. { echo "configure: error: *** You must supply a directory to --with-zlib-includes." 1>&2; exit 1; }
  5396. ;;
  5397. esac
  5398. echo "$ac_t""$with_zlib_includes" 1>&6
  5399. if test -n "$with_zlib_includes" ; then
  5400. for dir in $with_zlib_includes; do
  5401. if test -d "$dir"; then
  5402. ZLIBINCPATH="$ZLIBINCPATH -I$dir"
  5403. else
  5404. { echo "configure: error: *** zlib includes directory $dir does not exist." 1>&2; exit 1; }
  5405. fi
  5406. done
  5407. fi
  5408. ac_save_cppflags="$CPPFLAGS"
  5409. CPPFLAGS="$ZLIBINCPATH $CPPFLAGS"
  5410. for ac_hdr in zlib.h
  5411. do
  5412. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  5413. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  5414. echo "configure:6362: checking for $ac_hdr" >&5
  5415. cat > conftest.$ac_ext <<EOF
  5416. #line 6365 "configure"
  5417. #include "confdefs.h"
  5418. #include <$ac_hdr>
  5419. EOF
  5420. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  5421. { (eval echo configure:6370: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  5422. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  5423. if test -z "$ac_err"; then
  5424. rm -rf conftest*
  5425. eval "ac_cv_header_$ac_safe=yes"
  5426. else
  5427. echo "$ac_err" >&5
  5428. echo "configure: failed program was:" >&5
  5429. cat conftest.$ac_ext >&5
  5430. rm -rf conftest*
  5431. eval "ac_cv_header_$ac_safe=no"
  5432. fi
  5433. rm -f conftest*
  5434. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  5435. echo "$ac_t""yes" 1>&6
  5436. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  5437. cat >> confdefs.h <<EOF
  5438. #define $ac_tr_hdr 1
  5439. EOF
  5440. else
  5441. echo "$ac_t""no" 1>&6
  5442. { echo "configure: error: *** Unable to locate zlib includes." 1>&2; exit 1; }
  5443. fi
  5444. done
  5445. CPPFLAGS=$ac_save_cppflags
  5446. # With zlib library directory
  5447. echo $ac_n "checking for location of zlib library""... $ac_c" 1>&6
  5448. echo "configure:6404: checking for location of zlib library" >&5
  5449. case "$with_zlib_libs" in
  5450. y | ye | yes | n | no)
  5451. { echo "configure: error: *** You must supply a directory to --with-zlib-libs." 1>&2; exit 1; }
  5452. ;;
  5453. esac
  5454. echo "$ac_t""$with_zlib_libs" 1>&6
  5455. if test -n "$with_zlib_libs"; then
  5456. for dir in $with_zlib_libs; do
  5457. if test -d "$dir"; then
  5458. ZLIBLIBPATH="$ZLIBLIBPATH -L$dir"
  5459. else
  5460. { echo "configure: error: *** zlib library directory $dir does not exist." 1>&2; exit 1; }
  5461. fi
  5462. done
  5463. fi
  5464. ac_save_ldflags="$LDFLAGS"
  5465. LDFLAGS="$ZLIBLIBPATH $LDFLAGS"
  5466. echo $ac_n "checking for deflate in -lz""... $ac_c" 1>&6
  5467. echo "configure:6429: checking for deflate in -lz" >&5
  5468. ac_lib_var=`echo z'_'deflate | sed 'y%./+-%__p_%'`
  5469. ac_save_LIBS="$LIBS"
  5470. LIBS="-lz $LIBS"
  5471. cat > conftest.$ac_ext <<EOF
  5472. #line 6435 "configure"
  5473. #include "confdefs.h"
  5474. /* Override any gcc2 internal prototype to avoid an error. */
  5475. /* We use char because int might match the return type of a gcc2
  5476. builtin and then its argument prototype would still apply. */
  5477. char deflate();
  5478. int main() {
  5479. deflate()
  5480. ; return 0; }
  5481. EOF
  5482. if { (eval echo configure:6446: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5483. rm -rf conftest*
  5484. eval "ac_cv_lib_$ac_lib_var=yes"
  5485. else
  5486. echo "configure: failed program was:" >&5
  5487. cat conftest.$ac_ext >&5
  5488. rm -rf conftest*
  5489. eval "ac_cv_lib_$ac_lib_var=no"
  5490. fi
  5491. rm -f conftest*
  5492. LIBS="$ac_save_LIBS"
  5493. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5494. echo "$ac_t""yes" 1>&6
  5495. ZLIB="$ZLIB -lz "
  5496. else
  5497. echo "$ac_t""no" 1>&6
  5498. LDFLAGS=${ac_save_ldflags}
  5499. { echo "configure: error: *** Unable to locate zlib library." 1>&2; exit 1; }
  5500. fi
  5501. LDFLAGS=${ac_save_ldflags}
  5502. #
  5503. # Done checking zlib
  5504. # Mandatory PROJ dependency
  5505. PROJINC=
  5506. PROJLIB=
  5507. PROJSHARE=
  5508. # With PROJ includes directory
  5509. echo $ac_n "checking for location of External PROJ.4 includes""... $ac_c" 1>&6
  5510. echo "configure:6494: checking for location of External PROJ.4 includes" >&5
  5511. case "$with_proj_includes" in
  5512. y | ye | yes | n | no)
  5513. { echo "configure: error: *** You must supply a directory to --with-proj-includes." 1>&2; exit 1; }
  5514. ;;
  5515. esac
  5516. echo "$ac_t""$with_proj_includes" 1>&6
  5517. if test -n "$with_proj_includes" ; then
  5518. for dir in $with_proj_includes; do
  5519. if test -d "$dir"; then
  5520. PROJINC="$PROJINC -I$dir"
  5521. else
  5522. { echo "configure: error: *** External PROJ.4 includes directory $dir does not exist." 1>&2; exit 1; }
  5523. fi
  5524. done
  5525. fi
  5526. ac_save_cppflags="$CPPFLAGS"
  5527. CPPFLAGS="$PROJINC $CPPFLAGS"
  5528. for ac_hdr in proj_api.h
  5529. do
  5530. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  5531. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  5532. echo "configure:6520: checking for $ac_hdr" >&5
  5533. cat > conftest.$ac_ext <<EOF
  5534. #line 6523 "configure"
  5535. #include "confdefs.h"
  5536. #include <$ac_hdr>
  5537. EOF
  5538. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  5539. { (eval echo configure:6528: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  5540. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  5541. if test -z "$ac_err"; then
  5542. rm -rf conftest*
  5543. eval "ac_cv_header_$ac_safe=yes"
  5544. else
  5545. echo "$ac_err" >&5
  5546. echo "configure: failed program was:" >&5
  5547. cat conftest.$ac_ext >&5
  5548. rm -rf conftest*
  5549. eval "ac_cv_header_$ac_safe=no"
  5550. fi
  5551. rm -f conftest*
  5552. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  5553. echo "$ac_t""yes" 1>&6
  5554. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  5555. cat >> confdefs.h <<EOF
  5556. #define $ac_tr_hdr 1
  5557. EOF
  5558. else
  5559. echo "$ac_t""no" 1>&6
  5560. { echo "configure: error: *** Unable to locate External PROJ.4 includes." 1>&2; exit 1; }
  5561. fi
  5562. done
  5563. CPPFLAGS=$ac_save_cppflags
  5564. # PROJ version check
  5565. if test "$cross_compiling" = yes; then
  5566. echo "configure: warning: *** Cannot check PROJ.4 version (cross-compiling)." 1>&2
  5567. else
  5568. echo $ac_n "checking External PROJ.4 version""... $ac_c" 1>&6
  5569. echo "configure:6565: checking External PROJ.4 version" >&5
  5570. ac_save_cppflags="$CPPFLAGS"
  5571. CPPFLAGS="$PROJINC $CPPFLAGS"
  5572. if test "$cross_compiling" = yes; then
  5573. proj_ver=0
  5574. echo "$ac_t""unknown (cross-compiling)" 1>&6
  5575. else
  5576. cat > conftest.$ac_ext <<EOF
  5577. #line 6573 "configure"
  5578. #include "confdefs.h"
  5579. #include <stdio.h>
  5580. #include <proj_api.h>
  5581. int main(void) {
  5582. FILE *fp = fopen("conftestdata","w");
  5583. fprintf(fp, "%d", PJ_VERSION);
  5584. return 0;
  5585. }
  5586. EOF
  5587. if { (eval echo configure:6585: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  5588. then
  5589. proj_ver=`cat conftestdata`
  5590. echo "$ac_t""$proj_ver" 1>&6
  5591. else
  5592. echo "configure: failed program was:" >&5
  5593. cat conftest.$ac_ext >&5
  5594. rm -fr conftest*
  5595. { echo "configure: error: *** Could not determine External PROJ.4 version." 1>&2; exit 1; }
  5596. fi
  5597. rm -fr conftest*
  5598. fi
  5599. CPPFLAGS=$ac_save_cppflags
  5600. if test `expr "$proj_ver" \< 446` = 1 ; then
  5601. { echo "configure: error: *** PROJ.4.4.6 or later is required." 1>&2; exit 1; }
  5602. fi
  5603. fi
  5604. # With PROJ library directory
  5605. echo $ac_n "checking for location of External PROJ.4 library""... $ac_c" 1>&6
  5606. echo "configure:6610: checking for location of External PROJ.4 library" >&5
  5607. case "$with_proj_libs" in
  5608. y | ye | yes | n | no)
  5609. { echo "configure: error: *** You must supply a directory to --with-proj-libs." 1>&2; exit 1; }
  5610. ;;
  5611. esac
  5612. echo "$ac_t""$with_proj_libs" 1>&6
  5613. if test -n "$with_proj_libs"; then
  5614. for dir in $with_proj_libs; do
  5615. if test -d "$dir"; then
  5616. PROJLIB="$PROJLIB -L$dir"
  5617. else
  5618. { echo "configure: error: *** External PROJ.4 library directory $dir does not exist." 1>&2; exit 1; }
  5619. fi
  5620. done
  5621. fi
  5622. ac_save_ldflags="$LDFLAGS"
  5623. LDFLAGS="$PROJLIB $LDFLAGS"
  5624. echo $ac_n "checking for pj_get_def in -lproj""... $ac_c" 1>&6
  5625. echo "configure:6635: checking for pj_get_def in -lproj" >&5
  5626. ac_lib_var=`echo proj'_'pj_get_def | sed 'y%./+-%__p_%'`
  5627. ac_save_LIBS="$LIBS"
  5628. LIBS="-lproj $LIBS"
  5629. cat > conftest.$ac_ext <<EOF
  5630. #line 6641 "configure"
  5631. #include "confdefs.h"
  5632. /* Override any gcc2 internal prototype to avoid an error. */
  5633. /* We use char because int might match the return type of a gcc2
  5634. builtin and then its argument prototype would still apply. */
  5635. char pj_get_def();
  5636. int main() {
  5637. pj_get_def()
  5638. ; return 0; }
  5639. EOF
  5640. if { (eval echo configure:6652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5641. rm -rf conftest*
  5642. eval "ac_cv_lib_$ac_lib_var=yes"
  5643. else
  5644. echo "configure: failed program was:" >&5
  5645. cat conftest.$ac_ext >&5
  5646. rm -rf conftest*
  5647. eval "ac_cv_lib_$ac_lib_var=no"
  5648. fi
  5649. rm -f conftest*
  5650. LIBS="$ac_save_LIBS"
  5651. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5652. echo "$ac_t""yes" 1>&6
  5653. PROJLIB="$PROJLIB -lproj "
  5654. else
  5655. echo "$ac_t""no" 1>&6
  5656. LDFLAGS=${ac_save_ldflags}
  5657. { echo "configure: error: *** Unable to locate External PROJ.4 library." 1>&2; exit 1; }
  5658. fi
  5659. LDFLAGS=${ac_save_ldflags}
  5660. # With PROJ share directory
  5661. echo $ac_n "checking for location of External PROJ.4 data files""... $ac_c" 1>&6
  5662. echo "configure:6686: checking for location of External PROJ.4 data files" >&5
  5663. case "$with_proj_share" in
  5664. y | ye | yes | n | no)
  5665. { echo "configure: error: *** You must supply a directory to --with-proj-share." 1>&2; exit 1; }
  5666. ;;
  5667. esac
  5668. echo "$ac_t""$with_proj_share" 1>&6
  5669. if test -n "$with_proj_share" ; then
  5670. if test -d "$with_proj_share"; then
  5671. PROJSHARE="$with_proj_share"
  5672. else
  5673. { echo "configure: error: *** External PROJ.4 data directory $dir does not exist." 1>&2; exit 1; }
  5674. fi
  5675. fi
  5676. if test -z "$PROJSHARE" ; then
  5677. echo "configure: warning: *** External PROJ.4 directory not specified; default will be used" 1>&2
  5678. PROJSHARE=/usr/local/share/proj
  5679. fi
  5680. # LOC_CHECK_SHARE does not work when cross compiling
  5681. if test "$cross_compiling" = "yes" ; then
  5682. echo $ac_n "checking for epsg""... $ac_c" 1>&6
  5683. echo "configure:6710: checking for epsg" >&5
  5684. echo "$ac_t""unknown (cross-compiling)" 1>&6
  5685. else
  5686. ac_safe=`echo "$PROJSHARE/epsg" | sed 'y%./+-%__p_%'`
  5687. echo $ac_n "checking for $PROJSHARE/epsg""... $ac_c" 1>&6
  5688. echo "configure:6717: checking for $PROJSHARE/epsg" >&5
  5689. if test "$cross_compiling" = yes; then
  5690. { echo "configure: error: Cannot check for file existence when cross compiling" 1>&2; exit 1; }
  5691. else
  5692. if test -r $PROJSHARE/epsg; then
  5693. eval "ac_cv_file_$ac_safe=yes"
  5694. else
  5695. eval "ac_cv_file_$ac_safe=no"
  5696. fi
  5697. fi
  5698. if eval "test \"`echo '$ac_cv_file_'$ac_safe`\" = yes"; then
  5699. echo "$ac_t""yes" 1>&6
  5700. :
  5701. else
  5702. echo "$ac_t""no" 1>&6
  5703. echo "configure: warning: *** Unable to locate PROJ data files." 1>&2
  5704. fi
  5705. fi
  5706. # nad2bin needs to be in path for installing datum gridshift files
  5707. # Extract the first word of "nad2bin", so it can be a program name with args.
  5708. set dummy nad2bin; ac_word=$2
  5709. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  5710. echo "configure:6749: checking for $ac_word" >&5
  5711. case "$NAD2BIN" in
  5712. /*)
  5713. ac_cv_path_NAD2BIN="$NAD2BIN" # Let the user override the test with a path.
  5714. ;;
  5715. ?:/*)
  5716. ac_cv_path_NAD2BIN="$NAD2BIN" # Let the user override the test with a dos path.
  5717. ;;
  5718. *)
  5719. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  5720. ac_dummy="$PATH"
  5721. for ac_dir in $ac_dummy; do
  5722. test -z "$ac_dir" && ac_dir=.
  5723. if test -f $ac_dir/$ac_word; then
  5724. ac_cv_path_NAD2BIN="$ac_dir/$ac_word"
  5725. break
  5726. fi
  5727. done
  5728. IFS="$ac_save_ifs"
  5729. test -z "$ac_cv_path_NAD2BIN" && ac_cv_path_NAD2BIN="no"
  5730. ;;
  5731. esac
  5732. NAD2BIN="$ac_cv_path_NAD2BIN"
  5733. if test -n "$NAD2BIN"; then
  5734. echo "$ac_t""$NAD2BIN" 1>&6
  5735. else
  5736. echo "$ac_t""no" 1>&6
  5737. fi
  5738. if test "$NAD2BIN" = "no"; then
  5739. { echo "configure: error: *** Unable to locate nad2bin (needs to be in PATH)." 1>&2; exit 1; }
  5740. fi
  5741. # Done checking PROJ
  5742. # Enable regex option
  5743. echo $ac_n "checking whether to use regex""... $ac_c" 1>&6
  5744. echo "configure:6789: checking whether to use regex" >&5
  5745. echo "$ac_t"""$with_regex"" 1>&6
  5746. case "$with_regex" in
  5747. "no") USE_REGEX= ;;
  5748. "yes") USE_REGEX="1" ;;
  5749. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  5750. esac
  5751. REGEXINCPATH=
  5752. REGEXLIBPATH=
  5753. REGEXLIB=
  5754. if test -n "$USE_REGEX"; then
  5755. # With regex includes directory
  5756. echo $ac_n "checking for location of regex includes""... $ac_c" 1>&6
  5757. echo "configure:6809: checking for location of regex includes" >&5
  5758. case "$with_regex_includes" in
  5759. y | ye | yes | n | no)
  5760. { echo "configure: error: *** You must supply a directory to --with-regex-includes." 1>&2; exit 1; }
  5761. ;;
  5762. esac
  5763. echo "$ac_t""$with_regex_includes" 1>&6
  5764. if test -n "$with_regex_includes" ; then
  5765. for dir in $with_regex_includes; do
  5766. if test -d "$dir"; then
  5767. REGEXINCPATH="$REGEXINCPATH -I$dir"
  5768. else
  5769. { echo "configure: error: *** regex includes directory $dir does not exist." 1>&2; exit 1; }
  5770. fi
  5771. done
  5772. fi
  5773. ac_save_cppflags="$CPPFLAGS"
  5774. CPPFLAGS="$REGEXINCPATH $CPPFLAGS"
  5775. for ac_hdr in regex.h
  5776. do
  5777. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  5778. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  5779. echo "configure:6835: checking for $ac_hdr" >&5
  5780. cat > conftest.$ac_ext <<EOF
  5781. #line 6838 "configure"
  5782. #include "confdefs.h"
  5783. #include <$ac_hdr>
  5784. EOF
  5785. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  5786. { (eval echo configure:6843: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  5787. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  5788. if test -z "$ac_err"; then
  5789. rm -rf conftest*
  5790. eval "ac_cv_header_$ac_safe=yes"
  5791. else
  5792. echo "$ac_err" >&5
  5793. echo "configure: failed program was:" >&5
  5794. cat conftest.$ac_ext >&5
  5795. rm -rf conftest*
  5796. eval "ac_cv_header_$ac_safe=no"
  5797. fi
  5798. rm -f conftest*
  5799. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  5800. echo "$ac_t""yes" 1>&6
  5801. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  5802. cat >> confdefs.h <<EOF
  5803. #define $ac_tr_hdr 1
  5804. EOF
  5805. else
  5806. echo "$ac_t""no" 1>&6
  5807. { echo "configure: error: *** Unable to locate regex includes." 1>&2; exit 1; }
  5808. fi
  5809. done
  5810. CPPFLAGS=$ac_save_cppflags
  5811. # With regex library directory
  5812. echo $ac_n "checking for location of regex library""... $ac_c" 1>&6
  5813. echo "configure:6877: checking for location of regex library" >&5
  5814. case "$with_regex_libs" in
  5815. y | ye | yes | n | no)
  5816. { echo "configure: error: *** You must supply a directory to --with-regex-libs." 1>&2; exit 1; }
  5817. ;;
  5818. esac
  5819. echo "$ac_t""$with_regex_libs" 1>&6
  5820. if test -n "$with_regex_libs"; then
  5821. for dir in $with_regex_libs; do
  5822. if test -d "$dir"; then
  5823. REGEXLIBPATH="$REGEXLIBPATH -L$dir"
  5824. else
  5825. { echo "configure: error: *** regex library directory $dir does not exist." 1>&2; exit 1; }
  5826. fi
  5827. done
  5828. fi
  5829. ac_save_libs="$LIBS"
  5830. ac_save_ldflags="$LDFLAGS"
  5831. LIBS=" $LIBS"
  5832. LDFLAGS=" $LDFLAGS"
  5833. echo $ac_n "checking for regcomp""... $ac_c" 1>&6
  5834. echo "configure:6902: checking for regcomp" >&5
  5835. cat > conftest.$ac_ext <<EOF
  5836. #line 6905 "configure"
  5837. #include "confdefs.h"
  5838. /* System header to define __stub macros and hopefully few prototypes,
  5839. which can conflict with char regcomp(); below. */
  5840. #include <assert.h>
  5841. /* Override any gcc2 internal prototype to avoid an error. */
  5842. /* We use char because int might match the return type of a gcc2
  5843. builtin and then its argument prototype would still apply. */
  5844. char regcomp();
  5845. int main() {
  5846. /* The GNU C library defines this for functions which it implements
  5847. to always fail with ENOSYS. Some functions are actually named
  5848. something starting with __ and the normal name is an alias. */
  5849. #if defined (__stub_regcomp) || defined (__stub___regcomp)
  5850. choke me
  5851. #else
  5852. regcomp();
  5853. #endif
  5854. ; return 0; }
  5855. EOF
  5856. if { (eval echo configure:6928: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5857. rm -rf conftest*
  5858. eval "ac_cv_func_regcomp=yes"
  5859. else
  5860. echo "configure: failed program was:" >&5
  5861. cat conftest.$ac_ext >&5
  5862. rm -rf conftest*
  5863. eval "ac_cv_func_regcomp=no"
  5864. fi
  5865. rm -f conftest*
  5866. if eval "test \"`echo '$ac_cv_func_'regcomp`\" = yes"; then
  5867. echo "$ac_t""yes" 1>&6
  5868. REGEXLIB="$REGEXLIB "
  5869. else
  5870. echo "$ac_t""no" 1>&6
  5871. ac_save_ldflags="$LDFLAGS"
  5872. LDFLAGS="$REGEXLIBPATH $LDFLAGS"
  5873. echo $ac_n "checking for regcomp in -lregex""... $ac_c" 1>&6
  5874. echo "configure:6955: checking for regcomp in -lregex" >&5
  5875. ac_lib_var=`echo regex'_'regcomp | sed 'y%./+-%__p_%'`
  5876. ac_save_LIBS="$LIBS"
  5877. LIBS="-lregex $LIBS"
  5878. cat > conftest.$ac_ext <<EOF
  5879. #line 6961 "configure"
  5880. #include "confdefs.h"
  5881. /* Override any gcc2 internal prototype to avoid an error. */
  5882. /* We use char because int might match the return type of a gcc2
  5883. builtin and then its argument prototype would still apply. */
  5884. char regcomp();
  5885. int main() {
  5886. regcomp()
  5887. ; return 0; }
  5888. EOF
  5889. if { (eval echo configure:6972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  5890. rm -rf conftest*
  5891. eval "ac_cv_lib_$ac_lib_var=yes"
  5892. else
  5893. echo "configure: failed program was:" >&5
  5894. cat conftest.$ac_ext >&5
  5895. rm -rf conftest*
  5896. eval "ac_cv_lib_$ac_lib_var=no"
  5897. fi
  5898. rm -f conftest*
  5899. LIBS="$ac_save_LIBS"
  5900. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  5901. echo "$ac_t""yes" 1>&6
  5902. REGEXLIB="$REGEXLIB -lregex "
  5903. else
  5904. echo "$ac_t""no" 1>&6
  5905. LDFLAGS=${ac_save_ldflags}
  5906. { echo "configure: error: *** Unable to locate regex library." 1>&2; exit 1; }
  5907. fi
  5908. LDFLAGS=${ac_save_ldflags}
  5909. fi
  5910. LIBS=${ac_save_libs}
  5911. LDFLAGS=${ac_save_ldflags}
  5912. fi # $USE_REGEX
  5913. # Done checking regex
  5914. # Enable Readline option
  5915. echo $ac_n "checking whether to use Readline""... $ac_c" 1>&6
  5916. echo "configure:7022: checking whether to use Readline" >&5
  5917. echo "$ac_t"""$with_readline"" 1>&6
  5918. case "$with_readline" in
  5919. "no") USE_READLINE= ;;
  5920. "yes") USE_READLINE="1" ;;
  5921. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  5922. esac
  5923. READLINEINCPATH=
  5924. READLINELIBPATH=
  5925. READLINELIB=
  5926. HISTORYLIB=
  5927. if test -n "$USE_READLINE"; then
  5928. # With Readline includes directory
  5929. echo $ac_n "checking for location of Readline includes""... $ac_c" 1>&6
  5930. echo "configure:7043: checking for location of Readline includes" >&5
  5931. case "$with_readline_includes" in
  5932. y | ye | yes | n | no)
  5933. { echo "configure: error: *** You must supply a directory to --with-readline-includes." 1>&2; exit 1; }
  5934. ;;
  5935. esac
  5936. echo "$ac_t""$with_readline_includes" 1>&6
  5937. if test -n "$with_readline_includes" ; then
  5938. for dir in $with_readline_includes; do
  5939. if test -d "$dir"; then
  5940. READLINEINCPATH="$READLINEINCPATH -I$dir"
  5941. else
  5942. { echo "configure: error: *** Readline includes directory $dir does not exist." 1>&2; exit 1; }
  5943. fi
  5944. done
  5945. fi
  5946. ac_save_cppflags="$CPPFLAGS"
  5947. CPPFLAGS="$READLINEINCPATH $CPPFLAGS"
  5948. for ac_hdr in readline/readline.h
  5949. do
  5950. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  5951. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  5952. echo "configure:7069: checking for $ac_hdr" >&5
  5953. cat > conftest.$ac_ext <<EOF
  5954. #line 7072 "configure"
  5955. #include "confdefs.h"
  5956. #include <$ac_hdr>
  5957. EOF
  5958. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  5959. { (eval echo configure:7077: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  5960. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  5961. if test -z "$ac_err"; then
  5962. rm -rf conftest*
  5963. eval "ac_cv_header_$ac_safe=yes"
  5964. else
  5965. echo "$ac_err" >&5
  5966. echo "configure: failed program was:" >&5
  5967. cat conftest.$ac_ext >&5
  5968. rm -rf conftest*
  5969. eval "ac_cv_header_$ac_safe=no"
  5970. fi
  5971. rm -f conftest*
  5972. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  5973. echo "$ac_t""yes" 1>&6
  5974. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  5975. cat >> confdefs.h <<EOF
  5976. #define $ac_tr_hdr 1
  5977. EOF
  5978. else
  5979. echo "$ac_t""no" 1>&6
  5980. { echo "configure: error: *** Unable to locate Readline includes." 1>&2; exit 1; }
  5981. fi
  5982. done
  5983. CPPFLAGS=$ac_save_cppflags
  5984. ac_save_cppflags="$CPPFLAGS"
  5985. CPPFLAGS="$READLINEINCPATH $CPPFLAGS"
  5986. for ac_hdr in readline/history.h
  5987. do
  5988. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  5989. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  5990. echo "configure:7113: checking for $ac_hdr" >&5
  5991. cat > conftest.$ac_ext <<EOF
  5992. #line 7116 "configure"
  5993. #include "confdefs.h"
  5994. #include <$ac_hdr>
  5995. EOF
  5996. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  5997. { (eval echo configure:7121: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  5998. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  5999. if test -z "$ac_err"; then
  6000. rm -rf conftest*
  6001. eval "ac_cv_header_$ac_safe=yes"
  6002. else
  6003. echo "$ac_err" >&5
  6004. echo "configure: failed program was:" >&5
  6005. cat conftest.$ac_ext >&5
  6006. rm -rf conftest*
  6007. eval "ac_cv_header_$ac_safe=no"
  6008. fi
  6009. rm -f conftest*
  6010. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  6011. echo "$ac_t""yes" 1>&6
  6012. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  6013. cat >> confdefs.h <<EOF
  6014. #define $ac_tr_hdr 1
  6015. EOF
  6016. else
  6017. echo "$ac_t""no" 1>&6
  6018. { echo "configure: error: *** Unable to locate Readline includes." 1>&2; exit 1; }
  6019. fi
  6020. done
  6021. CPPFLAGS=$ac_save_cppflags
  6022. # With Readline library directory
  6023. echo $ac_n "checking for location of Readline library""... $ac_c" 1>&6
  6024. echo "configure:7155: checking for location of Readline library" >&5
  6025. case "$with_readline_libs" in
  6026. y | ye | yes | n | no)
  6027. { echo "configure: error: *** You must supply a directory to --with-readline-libs." 1>&2; exit 1; }
  6028. ;;
  6029. esac
  6030. echo "$ac_t""$with_readline_libs" 1>&6
  6031. if test -n "$with_readline_libs"; then
  6032. for dir in $with_readline_libs; do
  6033. if test -d "$dir"; then
  6034. READLINELIBPATH="$READLINELIBPATH -L$dir"
  6035. else
  6036. { echo "configure: error: *** Readline library directory $dir does not exist." 1>&2; exit 1; }
  6037. fi
  6038. done
  6039. fi
  6040. ac_save_ldflags="$LDFLAGS"
  6041. LDFLAGS="$READLINELIBPATH $LDFLAGS"
  6042. echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
  6043. echo "configure:7180: checking for readline in -lreadline" >&5
  6044. ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'`
  6045. ac_save_LIBS="$LIBS"
  6046. LIBS="-lreadline $LIBS"
  6047. cat > conftest.$ac_ext <<EOF
  6048. #line 7186 "configure"
  6049. #include "confdefs.h"
  6050. /* Override any gcc2 internal prototype to avoid an error. */
  6051. /* We use char because int might match the return type of a gcc2
  6052. builtin and then its argument prototype would still apply. */
  6053. char readline();
  6054. int main() {
  6055. readline()
  6056. ; return 0; }
  6057. EOF
  6058. if { (eval echo configure:7197: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6059. rm -rf conftest*
  6060. eval "ac_cv_lib_$ac_lib_var=yes"
  6061. else
  6062. echo "configure: failed program was:" >&5
  6063. cat conftest.$ac_ext >&5
  6064. rm -rf conftest*
  6065. eval "ac_cv_lib_$ac_lib_var=no"
  6066. fi
  6067. rm -f conftest*
  6068. LIBS="$ac_save_LIBS"
  6069. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6070. echo "$ac_t""yes" 1>&6
  6071. READLINELIB="$READLINELIB -lreadline "
  6072. else
  6073. echo "$ac_t""no" 1>&6
  6074. LDFLAGS=${ac_save_ldflags}
  6075. { echo "configure: error: *** Unable to locate Readline library." 1>&2; exit 1; }
  6076. fi
  6077. LDFLAGS=${ac_save_ldflags}
  6078. ac_save_ldflags="$LDFLAGS"
  6079. LDFLAGS="$READLINELIBPATH $LDFLAGS"
  6080. echo $ac_n "checking for add_history in -lhistory""... $ac_c" 1>&6
  6081. echo "configure:7232: checking for add_history in -lhistory" >&5
  6082. ac_lib_var=`echo history'_'add_history | sed 'y%./+-%__p_%'`
  6083. ac_save_LIBS="$LIBS"
  6084. LIBS="-lhistory $LIBS"
  6085. cat > conftest.$ac_ext <<EOF
  6086. #line 7238 "configure"
  6087. #include "confdefs.h"
  6088. /* Override any gcc2 internal prototype to avoid an error. */
  6089. /* We use char because int might match the return type of a gcc2
  6090. builtin and then its argument prototype would still apply. */
  6091. char add_history();
  6092. int main() {
  6093. add_history()
  6094. ; return 0; }
  6095. EOF
  6096. if { (eval echo configure:7249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6097. rm -rf conftest*
  6098. eval "ac_cv_lib_$ac_lib_var=yes"
  6099. else
  6100. echo "configure: failed program was:" >&5
  6101. cat conftest.$ac_ext >&5
  6102. rm -rf conftest*
  6103. eval "ac_cv_lib_$ac_lib_var=no"
  6104. fi
  6105. rm -f conftest*
  6106. LIBS="$ac_save_LIBS"
  6107. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6108. echo "$ac_t""yes" 1>&6
  6109. HISTORYLIB="$HISTORYLIB -lhistory "
  6110. else
  6111. echo "$ac_t""no" 1>&6
  6112. LDFLAGS=${ac_save_ldflags}
  6113. { echo "configure: error: *** Unable to locate History library." 1>&2; exit 1; }
  6114. fi
  6115. LDFLAGS=${ac_save_ldflags}
  6116. fi # $USE_READLINE
  6117. # Done checking Readline
  6118. # Enable JPEG option
  6119. echo $ac_n "checking whether to use JPEG""... $ac_c" 1>&6
  6120. echo "configure:7292: checking whether to use JPEG" >&5
  6121. echo "$ac_t"""$with_jpeg"" 1>&6
  6122. case "$with_jpeg" in
  6123. "no") USE_JPEG= ;;
  6124. "yes") USE_JPEG="1" ;;
  6125. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  6126. esac
  6127. JPEGINCPATH=
  6128. JPEGLIBPATH=
  6129. JPEGLIB=
  6130. if test -n "$USE_JPEG"; then
  6131. # With JPEG includes directory
  6132. echo $ac_n "checking for location of JPEG includes""... $ac_c" 1>&6
  6133. echo "configure:7312: checking for location of JPEG includes" >&5
  6134. case "$with_jpeg_includes" in
  6135. y | ye | yes | n | no)
  6136. { echo "configure: error: *** You must supply a directory to --with-jpeg-includes." 1>&2; exit 1; }
  6137. ;;
  6138. esac
  6139. echo "$ac_t""$with_jpeg_includes" 1>&6
  6140. if test -n "$with_jpeg_includes" ; then
  6141. for dir in $with_jpeg_includes; do
  6142. if test -d "$dir"; then
  6143. JPEGINCPATH="$JPEGINCPATH -I$dir"
  6144. else
  6145. { echo "configure: error: *** JPEG includes directory $dir does not exist." 1>&2; exit 1; }
  6146. fi
  6147. done
  6148. fi
  6149. ac_save_cppflags="$CPPFLAGS"
  6150. CPPFLAGS="$JPEGINCPATH $CPPFLAGS"
  6151. for ac_hdr in jpeglib.h
  6152. do
  6153. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  6154. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  6155. echo "configure:7338: checking for $ac_hdr" >&5
  6156. cat > conftest.$ac_ext <<EOF
  6157. #line 7341 "configure"
  6158. #include "confdefs.h"
  6159. #include <$ac_hdr>
  6160. EOF
  6161. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  6162. { (eval echo configure:7346: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  6163. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  6164. if test -z "$ac_err"; then
  6165. rm -rf conftest*
  6166. eval "ac_cv_header_$ac_safe=yes"
  6167. else
  6168. echo "$ac_err" >&5
  6169. echo "configure: failed program was:" >&5
  6170. cat conftest.$ac_ext >&5
  6171. rm -rf conftest*
  6172. eval "ac_cv_header_$ac_safe=no"
  6173. fi
  6174. rm -f conftest*
  6175. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  6176. echo "$ac_t""yes" 1>&6
  6177. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  6178. cat >> confdefs.h <<EOF
  6179. #define $ac_tr_hdr 1
  6180. EOF
  6181. else
  6182. echo "$ac_t""no" 1>&6
  6183. { echo "configure: error: *** Unable to locate JPEG includes." 1>&2; exit 1; }
  6184. fi
  6185. done
  6186. CPPFLAGS=$ac_save_cppflags
  6187. # With JPEG library directory
  6188. echo $ac_n "checking for location of JPEG library""... $ac_c" 1>&6
  6189. echo "configure:7380: checking for location of JPEG library" >&5
  6190. case "$with_jpeg_libs" in
  6191. y | ye | yes | n | no)
  6192. { echo "configure: error: *** You must supply a directory to --with-jpeg-libs." 1>&2; exit 1; }
  6193. ;;
  6194. esac
  6195. echo "$ac_t""$with_jpeg_libs" 1>&6
  6196. if test -n "$with_jpeg_libs"; then
  6197. for dir in $with_jpeg_libs; do
  6198. if test -d "$dir"; then
  6199. JPEGLIBPATH="$JPEGLIBPATH -L$dir"
  6200. else
  6201. { echo "configure: error: *** JPEG library directory $dir does not exist." 1>&2; exit 1; }
  6202. fi
  6203. done
  6204. fi
  6205. ac_save_ldflags="$LDFLAGS"
  6206. LDFLAGS="$JPEGLIBPATH $LDFLAGS"
  6207. echo $ac_n "checking for jpeg_start_compress in -ljpeg""... $ac_c" 1>&6
  6208. echo "configure:7407: checking for jpeg_start_compress in -ljpeg" >&5
  6209. ac_lib_var=`echo jpeg'_'jpeg_start_compress | sed 'y%./+-%__p_%'`
  6210. ac_save_LIBS="$LIBS"
  6211. LIBS="-ljpeg $LIBS"
  6212. cat > conftest.$ac_ext <<EOF
  6213. #line 7413 "configure"
  6214. #include "confdefs.h"
  6215. /* Override any gcc2 internal prototype to avoid an error. */
  6216. /* We use char because int might match the return type of a gcc2
  6217. builtin and then its argument prototype would still apply. */
  6218. char jpeg_start_compress();
  6219. int main() {
  6220. jpeg_start_compress()
  6221. ; return 0; }
  6222. EOF
  6223. if { (eval echo configure:7424: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6224. rm -rf conftest*
  6225. eval "ac_cv_lib_$ac_lib_var=yes"
  6226. else
  6227. echo "configure: failed program was:" >&5
  6228. cat conftest.$ac_ext >&5
  6229. rm -rf conftest*
  6230. eval "ac_cv_lib_$ac_lib_var=no"
  6231. fi
  6232. rm -f conftest*
  6233. LIBS="$ac_save_LIBS"
  6234. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6235. echo "$ac_t""yes" 1>&6
  6236. JPEGLIB="$JPEGLIB -ljpeg "
  6237. else
  6238. echo "$ac_t""no" 1>&6
  6239. echo $ac_n "checking for jpeg_start_compress in -ljpeg""... $ac_c" 1>&6
  6240. echo "configure:7443: checking for jpeg_start_compress in -ljpeg" >&5
  6241. ac_lib_var=`echo jpeg'_'jpeg_start_compress | sed 'y%./+-%__p_%'`
  6242. ac_save_LIBS="$LIBS"
  6243. LIBS="-ljpeg $ZLIB $LIBS"
  6244. cat > conftest.$ac_ext <<EOF
  6245. #line 7449 "configure"
  6246. #include "confdefs.h"
  6247. /* Override any gcc2 internal prototype to avoid an error. */
  6248. /* We use char because int might match the return type of a gcc2
  6249. builtin and then its argument prototype would still apply. */
  6250. char jpeg_start_compress();
  6251. int main() {
  6252. jpeg_start_compress()
  6253. ; return 0; }
  6254. EOF
  6255. if { (eval echo configure:7460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6256. rm -rf conftest*
  6257. eval "ac_cv_lib_$ac_lib_var=yes"
  6258. else
  6259. echo "configure: failed program was:" >&5
  6260. cat conftest.$ac_ext >&5
  6261. rm -rf conftest*
  6262. eval "ac_cv_lib_$ac_lib_var=no"
  6263. fi
  6264. rm -f conftest*
  6265. LIBS="$ac_save_LIBS"
  6266. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6267. echo "$ac_t""yes" 1>&6
  6268. JPEGLIB="$JPEGLIB -ljpeg $ZLIB"
  6269. else
  6270. echo "$ac_t""no" 1>&6
  6271. LDFLAGS=${ac_save_ldflags}
  6272. { echo "configure: error: *** Unable to locate JPEG library." 1>&2; exit 1; }
  6273. fi
  6274. fi
  6275. LDFLAGS=${ac_save_ldflags}
  6276. fi # $USE_JPEG
  6277. # Done checking JPEG
  6278. # GDAL option
  6279. echo $ac_n "checking whether to use GDAL""... $ac_c" 1>&6
  6280. echo "configure:7509: checking whether to use GDAL" >&5
  6281. GDAL_LIBS=
  6282. GDAL_CFLAGS=
  6283. USE_GDAL=
  6284. USE_OGR=
  6285. if test "`basename xx/$with_gdal`" = "gdal-config" ; then
  6286. GDAL_CONFIG="$with_gdal"
  6287. fi
  6288. if test "$with_gdal" = "no" ; then
  6289. echo "$ac_t""no" 1>&6
  6290. else
  6291. echo "$ac_t""yes" 1>&6
  6292. # Extract the first word of "gdal-config", so it can be a program name with args.
  6293. set dummy gdal-config; ac_word=$2
  6294. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  6295. echo "configure:7527: checking for $ac_word" >&5
  6296. case "$GDAL_CONFIG" in
  6297. /*)
  6298. ac_cv_path_GDAL_CONFIG="$GDAL_CONFIG" # Let the user override the test with a path.
  6299. ;;
  6300. ?:/*)
  6301. ac_cv_path_GDAL_CONFIG="$GDAL_CONFIG" # Let the user override the test with a dos path.
  6302. ;;
  6303. *)
  6304. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  6305. ac_dummy="$PATH"
  6306. for ac_dir in $ac_dummy; do
  6307. test -z "$ac_dir" && ac_dir=.
  6308. if test -f $ac_dir/$ac_word; then
  6309. ac_cv_path_GDAL_CONFIG="$ac_dir/$ac_word"
  6310. break
  6311. fi
  6312. done
  6313. IFS="$ac_save_ifs"
  6314. test -z "$ac_cv_path_GDAL_CONFIG" && ac_cv_path_GDAL_CONFIG="no"
  6315. ;;
  6316. esac
  6317. GDAL_CONFIG="$ac_cv_path_GDAL_CONFIG"
  6318. if test -n "$GDAL_CONFIG"; then
  6319. echo "$ac_t""$GDAL_CONFIG" 1>&6
  6320. else
  6321. echo "$ac_t""no" 1>&6
  6322. fi
  6323. if test "$GDAL_CONFIG" = "no" ; then
  6324. { echo "configure: error: *** couldn't find gdal-config" 1>&2; exit 1; }
  6325. fi
  6326. if test "$GDAL_CONFIG" != "" ; then
  6327. GDAL_LIBS=`"$GDAL_CONFIG" --libs`
  6328. GDAL_DEP_LIBS=`"$GDAL_CONFIG" --dep-libs`
  6329. GDAL_CFLAGS=`"$GDAL_CONFIG" --cflags`
  6330. USE_GDAL=1
  6331. if test `"$GDAL_CONFIG" --ogr-enabled` = "yes" ; then
  6332. cat >> confdefs.h <<\EOF
  6333. #define HAVE_OGR 1
  6334. EOF
  6335. USE_OGR=1
  6336. fi
  6337. fi
  6338. GDAL=
  6339. ac_save_libs="$LIBS"
  6340. ac_save_cflags="$CFLAGS"
  6341. LIBS="$LIBS $GDAL_LIBS"
  6342. CFLAGS="$CFLAGS $GDAL_CFLAGS"
  6343. cat > conftest.$ac_ext <<EOF
  6344. #line 7582 "configure"
  6345. #include "confdefs.h"
  6346. #include <gdal.h>
  6347. int main() {
  6348. GDALOpen("foo", GA_ReadOnly);
  6349. ; return 0; }
  6350. EOF
  6351. if { (eval echo configure:7589: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6352. :
  6353. else
  6354. echo "configure: failed program was:" >&5
  6355. cat conftest.$ac_ext >&5
  6356. rm -rf conftest*
  6357. LIBS="$LIBS $GDAL_DEP_LIBS"
  6358. cat > conftest.$ac_ext <<EOF
  6359. #line 7598 "configure"
  6360. #include "confdefs.h"
  6361. #include <gdal.h>
  6362. int main() {
  6363. GDALOpen("foo", GA_ReadOnly);
  6364. ; return 0; }
  6365. EOF
  6366. if { (eval echo configure:7605: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6367. rm -rf conftest*
  6368. GDAL_LIBS="$GDAL_LIBS $GDAL_DEP_LIBS"
  6369. else
  6370. echo "configure: failed program was:" >&5
  6371. cat conftest.$ac_ext >&5
  6372. rm -rf conftest*
  6373. { echo "configure: error: *** Unable to locate GDAL library." 1>&2; exit 1; }
  6374. fi
  6375. rm -f conftest*
  6376. fi
  6377. rm -f conftest*
  6378. LIBS=${ac_save_libs}
  6379. CFLAGS=${ac_save_cflags}
  6380. cat >> confdefs.h <<\EOF
  6381. #define HAVE_GDAL 1
  6382. EOF
  6383. fi
  6384. # GEOS option
  6385. echo $ac_n "checking whether to use GEOS""... $ac_c" 1>&6
  6386. echo "configure:7637: checking whether to use GEOS" >&5
  6387. GEOS_LIBS=
  6388. GGEOS_CFLAGS=
  6389. USE_GEOS=
  6390. if test "`basename xx/$with_geos`" = "geos-config" ; then
  6391. GEOS_CONFIG="$with_geos"
  6392. fi
  6393. if test "$with_geos" = "no" ; then
  6394. echo "$ac_t""no" 1>&6
  6395. else
  6396. echo "$ac_t""yes" 1>&6
  6397. # Extract the first word of "geos-config", so it can be a program name with args.
  6398. set dummy geos-config; ac_word=$2
  6399. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  6400. echo "configure:7654: checking for $ac_word" >&5
  6401. case "$GEOS_CONFIG" in
  6402. /*)
  6403. ac_cv_path_GEOS_CONFIG="$GEOS_CONFIG" # Let the user override the test with a path.
  6404. ;;
  6405. ?:/*)
  6406. ac_cv_path_GEOS_CONFIG="$GEOS_CONFIG" # Let the user override the test with a dos path.
  6407. ;;
  6408. *)
  6409. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  6410. ac_dummy="$PATH"
  6411. for ac_dir in $ac_dummy; do
  6412. test -z "$ac_dir" && ac_dir=.
  6413. if test -f $ac_dir/$ac_word; then
  6414. ac_cv_path_GEOS_CONFIG="$ac_dir/$ac_word"
  6415. break
  6416. fi
  6417. done
  6418. IFS="$ac_save_ifs"
  6419. test -z "$ac_cv_path_GEOS_CONFIG" && ac_cv_path_GEOS_CONFIG="no"
  6420. ;;
  6421. esac
  6422. GEOS_CONFIG="$ac_cv_path_GEOS_CONFIG"
  6423. if test -n "$GEOS_CONFIG"; then
  6424. echo "$ac_t""$GEOS_CONFIG" 1>&6
  6425. else
  6426. echo "$ac_t""no" 1>&6
  6427. fi
  6428. if test "$GEOS_CONFIG" = "no" ; then
  6429. { echo "configure: error: *** couldn't find geos-config" 1>&2; exit 1; }
  6430. fi
  6431. if test "$GEOS_CONFIG" != "" ; then
  6432. GEOS_LIBS=`"$GEOS_CONFIG" --libs`
  6433. GEOS_CFLAGS=`"$GEOS_CONFIG" --cflags`
  6434. USE_GEOS=1
  6435. fi
  6436. ac_save_cppflags="$CPPFLAGS"
  6437. CPPFLAGS="$GEOS_CFLAGS $CPPFLAGS"
  6438. for ac_hdr in geos_c.h
  6439. do
  6440. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  6441. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  6442. echo "configure:7702: checking for $ac_hdr" >&5
  6443. cat > conftest.$ac_ext <<EOF
  6444. #line 7705 "configure"
  6445. #include "confdefs.h"
  6446. #include <$ac_hdr>
  6447. EOF
  6448. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  6449. { (eval echo configure:7710: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  6450. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  6451. if test -z "$ac_err"; then
  6452. rm -rf conftest*
  6453. eval "ac_cv_header_$ac_safe=yes"
  6454. else
  6455. echo "$ac_err" >&5
  6456. echo "configure: failed program was:" >&5
  6457. cat conftest.$ac_ext >&5
  6458. rm -rf conftest*
  6459. eval "ac_cv_header_$ac_safe=no"
  6460. fi
  6461. rm -f conftest*
  6462. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  6463. echo "$ac_t""yes" 1>&6
  6464. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  6465. cat >> confdefs.h <<EOF
  6466. #define $ac_tr_hdr 1
  6467. EOF
  6468. else
  6469. echo "$ac_t""no" 1>&6
  6470. { echo "configure: error: *** Unable to locate GEOS includes." 1>&2; exit 1; }
  6471. fi
  6472. done
  6473. CPPFLAGS=$ac_save_cppflags
  6474. ac_save_ldflags="$LDFLAGS"
  6475. LDFLAGS="$GEOS_LIBS $LDFLAGS"
  6476. echo $ac_n "checking for GEOSGeom_createLinearRing in -lgeos""... $ac_c" 1>&6
  6477. echo "configure:7745: checking for GEOSGeom_createLinearRing in -lgeos" >&5
  6478. ac_lib_var=`echo geos'_'GEOSGeom_createLinearRing | sed 'y%./+-%__p_%'`
  6479. ac_save_LIBS="$LIBS"
  6480. LIBS="-lgeos $LIBS"
  6481. cat > conftest.$ac_ext <<EOF
  6482. #line 7751 "configure"
  6483. #include "confdefs.h"
  6484. /* Override any gcc2 internal prototype to avoid an error. */
  6485. /* We use char because int might match the return type of a gcc2
  6486. builtin and then its argument prototype would still apply. */
  6487. char GEOSGeom_createLinearRing();
  6488. int main() {
  6489. GEOSGeom_createLinearRing()
  6490. ; return 0; }
  6491. EOF
  6492. if { (eval echo configure:7762: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6493. rm -rf conftest*
  6494. eval "ac_cv_lib_$ac_lib_var=yes"
  6495. else
  6496. echo "configure: failed program was:" >&5
  6497. cat conftest.$ac_ext >&5
  6498. rm -rf conftest*
  6499. eval "ac_cv_lib_$ac_lib_var=no"
  6500. fi
  6501. rm -f conftest*
  6502. LIBS="$ac_save_LIBS"
  6503. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6504. echo "$ac_t""yes" 1>&6
  6505. GEOS_LIBS="$GEOS_LIBS -lgeos "
  6506. else
  6507. echo "$ac_t""no" 1>&6
  6508. LDFLAGS=${ac_save_ldflags}
  6509. { echo "configure: error: *** Unable to locate GEOS library." 1>&2; exit 1; }
  6510. fi
  6511. LDFLAGS=${ac_save_ldflags}
  6512. cat >> confdefs.h <<\EOF
  6513. #define HAVE_GEOS 1
  6514. EOF
  6515. fi
  6516. # Enable TIFF option
  6517. echo $ac_n "checking whether to use TIFF""... $ac_c" 1>&6
  6518. echo "configure:7805: checking whether to use TIFF" >&5
  6519. echo "$ac_t"""$with_tiff"" 1>&6
  6520. case "$with_tiff" in
  6521. "no") USE_TIFF= ;;
  6522. "yes") USE_TIFF="1" ;;
  6523. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  6524. esac
  6525. TIFF_INCLUDE_DIRS=
  6526. TIFF_LIBRARY_DIRS=
  6527. TIFFLIB=
  6528. if test -n "$USE_TIFF"; then
  6529. # With TIFF includes directory
  6530. echo $ac_n "checking for location of TIFF includes""... $ac_c" 1>&6
  6531. echo "configure:7825: checking for location of TIFF includes" >&5
  6532. case "$with_tiff_includes" in
  6533. y | ye | yes | n | no)
  6534. { echo "configure: error: *** You must supply a directory to --with-tiff-includes." 1>&2; exit 1; }
  6535. ;;
  6536. esac
  6537. echo "$ac_t""$with_tiff_includes" 1>&6
  6538. if test -n "$with_tiff_includes" ; then
  6539. for dir in $with_tiff_includes; do
  6540. if test -d "$dir"; then
  6541. TIFF_INCLUDE_DIRS="$TIFF_INCLUDE_DIRS -I$dir"
  6542. else
  6543. { echo "configure: error: *** TIFF includes directory $dir does not exist." 1>&2; exit 1; }
  6544. fi
  6545. done
  6546. fi
  6547. ac_save_cppflags="$CPPFLAGS"
  6548. CPPFLAGS="$TIFF_INCLUDE_DIRS $CPPFLAGS"
  6549. for ac_hdr in tiffio.h
  6550. do
  6551. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  6552. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  6553. echo "configure:7851: checking for $ac_hdr" >&5
  6554. cat > conftest.$ac_ext <<EOF
  6555. #line 7854 "configure"
  6556. #include "confdefs.h"
  6557. #include <$ac_hdr>
  6558. EOF
  6559. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  6560. { (eval echo configure:7859: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  6561. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  6562. if test -z "$ac_err"; then
  6563. rm -rf conftest*
  6564. eval "ac_cv_header_$ac_safe=yes"
  6565. else
  6566. echo "$ac_err" >&5
  6567. echo "configure: failed program was:" >&5
  6568. cat conftest.$ac_ext >&5
  6569. rm -rf conftest*
  6570. eval "ac_cv_header_$ac_safe=no"
  6571. fi
  6572. rm -f conftest*
  6573. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  6574. echo "$ac_t""yes" 1>&6
  6575. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  6576. cat >> confdefs.h <<EOF
  6577. #define $ac_tr_hdr 1
  6578. EOF
  6579. else
  6580. echo "$ac_t""no" 1>&6
  6581. { echo "configure: error: *** Unable to locate TIFF includes." 1>&2; exit 1; }
  6582. fi
  6583. done
  6584. CPPFLAGS=$ac_save_cppflags
  6585. # With TIFF library directory
  6586. echo $ac_n "checking for location of TIFF library""... $ac_c" 1>&6
  6587. echo "configure:7893: checking for location of TIFF library" >&5
  6588. case "$with_tiff_libs" in
  6589. y | ye | yes | n | no)
  6590. { echo "configure: error: *** You must supply a directory to --with-tiff-libs." 1>&2; exit 1; }
  6591. ;;
  6592. esac
  6593. echo "$ac_t""$with_tiff_libs" 1>&6
  6594. if test -n "$with_tiff_libs"; then
  6595. for dir in $with_tiff_libs; do
  6596. if test -d "$dir"; then
  6597. TIFF_LIBRARY_DIRS="$TIFF_LIBRARY_DIRS -L$dir"
  6598. else
  6599. { echo "configure: error: *** TIFF library directory $dir does not exist." 1>&2; exit 1; }
  6600. fi
  6601. done
  6602. fi
  6603. ac_save_ldflags="$LDFLAGS"
  6604. LDFLAGS="$TIFF_LIBRARY_DIRS $LDFLAGS"
  6605. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6606. echo "configure:7924: checking for TIFFOpen in -ltiff" >&5
  6607. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6608. ac_save_LIBS="$LIBS"
  6609. LIBS="-ltiff $LIBS"
  6610. cat > conftest.$ac_ext <<EOF
  6611. #line 7930 "configure"
  6612. #include "confdefs.h"
  6613. /* Override any gcc2 internal prototype to avoid an error. */
  6614. /* We use char because int might match the return type of a gcc2
  6615. builtin and then its argument prototype would still apply. */
  6616. char TIFFOpen();
  6617. int main() {
  6618. TIFFOpen()
  6619. ; return 0; }
  6620. EOF
  6621. if { (eval echo configure:7941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6622. rm -rf conftest*
  6623. eval "ac_cv_lib_$ac_lib_var=yes"
  6624. else
  6625. echo "configure: failed program was:" >&5
  6626. cat conftest.$ac_ext >&5
  6627. rm -rf conftest*
  6628. eval "ac_cv_lib_$ac_lib_var=no"
  6629. fi
  6630. rm -f conftest*
  6631. LIBS="$ac_save_LIBS"
  6632. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6633. echo "$ac_t""yes" 1>&6
  6634. TIFFLIB="$TIFFLIB -ltiff "
  6635. else
  6636. echo "$ac_t""no" 1>&6
  6637. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6638. echo "configure:7960: checking for TIFFOpen in -ltiff" >&5
  6639. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6640. ac_save_LIBS="$LIBS"
  6641. LIBS="-ltiff $MATHLIB $LIBS"
  6642. cat > conftest.$ac_ext <<EOF
  6643. #line 7966 "configure"
  6644. #include "confdefs.h"
  6645. /* Override any gcc2 internal prototype to avoid an error. */
  6646. /* We use char because int might match the return type of a gcc2
  6647. builtin and then its argument prototype would still apply. */
  6648. char TIFFOpen();
  6649. int main() {
  6650. TIFFOpen()
  6651. ; return 0; }
  6652. EOF
  6653. if { (eval echo configure:7977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6654. rm -rf conftest*
  6655. eval "ac_cv_lib_$ac_lib_var=yes"
  6656. else
  6657. echo "configure: failed program was:" >&5
  6658. cat conftest.$ac_ext >&5
  6659. rm -rf conftest*
  6660. eval "ac_cv_lib_$ac_lib_var=no"
  6661. fi
  6662. rm -f conftest*
  6663. LIBS="$ac_save_LIBS"
  6664. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6665. echo "$ac_t""yes" 1>&6
  6666. TIFFLIB="$TIFFLIB -ltiff $MATHLIB"
  6667. else
  6668. echo "$ac_t""no" 1>&6
  6669. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6670. echo "configure:7996: checking for TIFFOpen in -ltiff" >&5
  6671. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6672. ac_save_LIBS="$LIBS"
  6673. LIBS="-ltiff $ZLIB $LIBS"
  6674. cat > conftest.$ac_ext <<EOF
  6675. #line 8002 "configure"
  6676. #include "confdefs.h"
  6677. /* Override any gcc2 internal prototype to avoid an error. */
  6678. /* We use char because int might match the return type of a gcc2
  6679. builtin and then its argument prototype would still apply. */
  6680. char TIFFOpen();
  6681. int main() {
  6682. TIFFOpen()
  6683. ; return 0; }
  6684. EOF
  6685. if { (eval echo configure:8013: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6686. rm -rf conftest*
  6687. eval "ac_cv_lib_$ac_lib_var=yes"
  6688. else
  6689. echo "configure: failed program was:" >&5
  6690. cat conftest.$ac_ext >&5
  6691. rm -rf conftest*
  6692. eval "ac_cv_lib_$ac_lib_var=no"
  6693. fi
  6694. rm -f conftest*
  6695. LIBS="$ac_save_LIBS"
  6696. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6697. echo "$ac_t""yes" 1>&6
  6698. TIFFLIB="$TIFFLIB -ltiff $ZLIB"
  6699. else
  6700. echo "$ac_t""no" 1>&6
  6701. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6702. echo "configure:8032: checking for TIFFOpen in -ltiff" >&5
  6703. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6704. ac_save_LIBS="$LIBS"
  6705. LIBS="-ltiff $ZLIB $MATHLIB $LIBS"
  6706. cat > conftest.$ac_ext <<EOF
  6707. #line 8038 "configure"
  6708. #include "confdefs.h"
  6709. /* Override any gcc2 internal prototype to avoid an error. */
  6710. /* We use char because int might match the return type of a gcc2
  6711. builtin and then its argument prototype would still apply. */
  6712. char TIFFOpen();
  6713. int main() {
  6714. TIFFOpen()
  6715. ; return 0; }
  6716. EOF
  6717. if { (eval echo configure:8049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6718. rm -rf conftest*
  6719. eval "ac_cv_lib_$ac_lib_var=yes"
  6720. else
  6721. echo "configure: failed program was:" >&5
  6722. cat conftest.$ac_ext >&5
  6723. rm -rf conftest*
  6724. eval "ac_cv_lib_$ac_lib_var=no"
  6725. fi
  6726. rm -f conftest*
  6727. LIBS="$ac_save_LIBS"
  6728. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6729. echo "$ac_t""yes" 1>&6
  6730. TIFFLIB="$TIFFLIB -ltiff $ZLIB $MATHLIB"
  6731. else
  6732. echo "$ac_t""no" 1>&6
  6733. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6734. echo "configure:8068: checking for TIFFOpen in -ltiff" >&5
  6735. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6736. ac_save_LIBS="$LIBS"
  6737. LIBS="-ltiff $JPEGLIBPATH $JPEGLIB $LIBS"
  6738. cat > conftest.$ac_ext <<EOF
  6739. #line 8074 "configure"
  6740. #include "confdefs.h"
  6741. /* Override any gcc2 internal prototype to avoid an error. */
  6742. /* We use char because int might match the return type of a gcc2
  6743. builtin and then its argument prototype would still apply. */
  6744. char TIFFOpen();
  6745. int main() {
  6746. TIFFOpen()
  6747. ; return 0; }
  6748. EOF
  6749. if { (eval echo configure:8085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6750. rm -rf conftest*
  6751. eval "ac_cv_lib_$ac_lib_var=yes"
  6752. else
  6753. echo "configure: failed program was:" >&5
  6754. cat conftest.$ac_ext >&5
  6755. rm -rf conftest*
  6756. eval "ac_cv_lib_$ac_lib_var=no"
  6757. fi
  6758. rm -f conftest*
  6759. LIBS="$ac_save_LIBS"
  6760. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6761. echo "$ac_t""yes" 1>&6
  6762. TIFFLIB="$TIFFLIB -ltiff $JPEGLIBPATH $JPEGLIB"
  6763. else
  6764. echo "$ac_t""no" 1>&6
  6765. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6766. echo "configure:8104: checking for TIFFOpen in -ltiff" >&5
  6767. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6768. ac_save_LIBS="$LIBS"
  6769. LIBS="-ltiff $JPEGLIBPATH $JPEGLIB $MATHLIB $LIBS"
  6770. cat > conftest.$ac_ext <<EOF
  6771. #line 8110 "configure"
  6772. #include "confdefs.h"
  6773. /* Override any gcc2 internal prototype to avoid an error. */
  6774. /* We use char because int might match the return type of a gcc2
  6775. builtin and then its argument prototype would still apply. */
  6776. char TIFFOpen();
  6777. int main() {
  6778. TIFFOpen()
  6779. ; return 0; }
  6780. EOF
  6781. if { (eval echo configure:8121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6782. rm -rf conftest*
  6783. eval "ac_cv_lib_$ac_lib_var=yes"
  6784. else
  6785. echo "configure: failed program was:" >&5
  6786. cat conftest.$ac_ext >&5
  6787. rm -rf conftest*
  6788. eval "ac_cv_lib_$ac_lib_var=no"
  6789. fi
  6790. rm -f conftest*
  6791. LIBS="$ac_save_LIBS"
  6792. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6793. echo "$ac_t""yes" 1>&6
  6794. TIFFLIB="$TIFFLIB -ltiff $JPEGLIBPATH $JPEGLIB $MATHLIB"
  6795. else
  6796. echo "$ac_t""no" 1>&6
  6797. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6798. echo "configure:8140: checking for TIFFOpen in -ltiff" >&5
  6799. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6800. ac_save_LIBS="$LIBS"
  6801. LIBS="-ltiff $JPEGLIBPATH $JPEGLIB $ZLIB $LIBS"
  6802. cat > conftest.$ac_ext <<EOF
  6803. #line 8146 "configure"
  6804. #include "confdefs.h"
  6805. /* Override any gcc2 internal prototype to avoid an error. */
  6806. /* We use char because int might match the return type of a gcc2
  6807. builtin and then its argument prototype would still apply. */
  6808. char TIFFOpen();
  6809. int main() {
  6810. TIFFOpen()
  6811. ; return 0; }
  6812. EOF
  6813. if { (eval echo configure:8157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6814. rm -rf conftest*
  6815. eval "ac_cv_lib_$ac_lib_var=yes"
  6816. else
  6817. echo "configure: failed program was:" >&5
  6818. cat conftest.$ac_ext >&5
  6819. rm -rf conftest*
  6820. eval "ac_cv_lib_$ac_lib_var=no"
  6821. fi
  6822. rm -f conftest*
  6823. LIBS="$ac_save_LIBS"
  6824. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6825. echo "$ac_t""yes" 1>&6
  6826. TIFFLIB="$TIFFLIB -ltiff $JPEGLIBPATH $JPEGLIB $ZLIB"
  6827. else
  6828. echo "$ac_t""no" 1>&6
  6829. echo $ac_n "checking for TIFFOpen in -ltiff""... $ac_c" 1>&6
  6830. echo "configure:8176: checking for TIFFOpen in -ltiff" >&5
  6831. ac_lib_var=`echo tiff'_'TIFFOpen | sed 'y%./+-%__p_%'`
  6832. ac_save_LIBS="$LIBS"
  6833. LIBS="-ltiff $JPEGLIBPATH $JPEGLIB $ZLIB $MATHLIB $LIBS"
  6834. cat > conftest.$ac_ext <<EOF
  6835. #line 8182 "configure"
  6836. #include "confdefs.h"
  6837. /* Override any gcc2 internal prototype to avoid an error. */
  6838. /* We use char because int might match the return type of a gcc2
  6839. builtin and then its argument prototype would still apply. */
  6840. char TIFFOpen();
  6841. int main() {
  6842. TIFFOpen()
  6843. ; return 0; }
  6844. EOF
  6845. if { (eval echo configure:8193: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6846. rm -rf conftest*
  6847. eval "ac_cv_lib_$ac_lib_var=yes"
  6848. else
  6849. echo "configure: failed program was:" >&5
  6850. cat conftest.$ac_ext >&5
  6851. rm -rf conftest*
  6852. eval "ac_cv_lib_$ac_lib_var=no"
  6853. fi
  6854. rm -f conftest*
  6855. LIBS="$ac_save_LIBS"
  6856. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6857. echo "$ac_t""yes" 1>&6
  6858. TIFFLIB="$TIFFLIB -ltiff $JPEGLIBPATH $JPEGLIB $ZLIB $MATHLIB"
  6859. else
  6860. echo "$ac_t""no" 1>&6
  6861. LDFLAGS=${ac_save_ldflags}
  6862. { echo "configure: error: *** Unable to locate TIFF library." 1>&2; exit 1; }
  6863. fi
  6864. fi
  6865. fi
  6866. fi
  6867. fi
  6868. fi
  6869. fi
  6870. fi
  6871. LDFLAGS=${ac_save_ldflags}
  6872. fi # $USE_TIFF
  6873. # Done checking TIFF
  6874. # Enable PNG option
  6875. echo $ac_n "checking whether to use PNG""... $ac_c" 1>&6
  6876. echo "configure:8291: checking whether to use PNG" >&5
  6877. echo "$ac_t"""$with_png"" 1>&6
  6878. case "$with_png" in
  6879. "no") USE_PNG= ;;
  6880. "yes") USE_PNG="1" ;;
  6881. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  6882. esac
  6883. PNGINC=
  6884. PNGLIB=
  6885. if test -n "$USE_PNG"; then
  6886. # With PNG includes directory
  6887. echo $ac_n "checking for location of PNG includes""... $ac_c" 1>&6
  6888. echo "configure:8310: checking for location of PNG includes" >&5
  6889. case "$with_png_includes" in
  6890. y | ye | yes | n | no)
  6891. { echo "configure: error: *** You must supply a directory to --with-png-includes." 1>&2; exit 1; }
  6892. ;;
  6893. esac
  6894. echo "$ac_t""$with_png_includes" 1>&6
  6895. if test -n "$with_png_includes" ; then
  6896. for dir in $with_png_includes; do
  6897. if test -d "$dir"; then
  6898. PNGINC="$PNGINC -I$dir"
  6899. else
  6900. { echo "configure: error: *** PNG includes directory $dir does not exist." 1>&2; exit 1; }
  6901. fi
  6902. done
  6903. fi
  6904. ac_save_cppflags="$CPPFLAGS"
  6905. CPPFLAGS="$PNGINC $CPPFLAGS"
  6906. for ac_hdr in png.h
  6907. do
  6908. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  6909. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  6910. echo "configure:8336: checking for $ac_hdr" >&5
  6911. cat > conftest.$ac_ext <<EOF
  6912. #line 8339 "configure"
  6913. #include "confdefs.h"
  6914. #include <$ac_hdr>
  6915. EOF
  6916. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  6917. { (eval echo configure:8344: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  6918. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  6919. if test -z "$ac_err"; then
  6920. rm -rf conftest*
  6921. eval "ac_cv_header_$ac_safe=yes"
  6922. else
  6923. echo "$ac_err" >&5
  6924. echo "configure: failed program was:" >&5
  6925. cat conftest.$ac_ext >&5
  6926. rm -rf conftest*
  6927. eval "ac_cv_header_$ac_safe=no"
  6928. fi
  6929. rm -f conftest*
  6930. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  6931. echo "$ac_t""yes" 1>&6
  6932. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  6933. cat >> confdefs.h <<EOF
  6934. #define $ac_tr_hdr 1
  6935. EOF
  6936. else
  6937. echo "$ac_t""no" 1>&6
  6938. { echo "configure: error: *** Unable to locate PNG includes." 1>&2; exit 1; }
  6939. fi
  6940. done
  6941. CPPFLAGS=$ac_save_cppflags
  6942. # With PNG library directory
  6943. echo $ac_n "checking for location of PNG library""... $ac_c" 1>&6
  6944. echo "configure:8378: checking for location of PNG library" >&5
  6945. case "$with_png_libs" in
  6946. y | ye | yes | n | no)
  6947. { echo "configure: error: *** You must supply a directory to --with-png-libs." 1>&2; exit 1; }
  6948. ;;
  6949. esac
  6950. echo "$ac_t""$with_png_libs" 1>&6
  6951. if test -n "$with_png_libs"; then
  6952. for dir in $with_png_libs; do
  6953. if test -d "$dir"; then
  6954. PNGLIB="$PNGLIB -L$dir"
  6955. else
  6956. { echo "configure: error: *** PNG library directory $dir does not exist." 1>&2; exit 1; }
  6957. fi
  6958. done
  6959. fi
  6960. ac_save_ldflags="$LDFLAGS"
  6961. LDFLAGS="$PNGLIB $LDFLAGS"
  6962. echo $ac_n "checking for png_read_image in -lpng""... $ac_c" 1>&6
  6963. echo "configure:8403: checking for png_read_image in -lpng" >&5
  6964. ac_lib_var=`echo png'_'png_read_image | sed 'y%./+-%__p_%'`
  6965. ac_save_LIBS="$LIBS"
  6966. LIBS="-lpng $ZLIB $MATHLIB $LIBS"
  6967. cat > conftest.$ac_ext <<EOF
  6968. #line 8409 "configure"
  6969. #include "confdefs.h"
  6970. /* Override any gcc2 internal prototype to avoid an error. */
  6971. /* We use char because int might match the return type of a gcc2
  6972. builtin and then its argument prototype would still apply. */
  6973. char png_read_image();
  6974. int main() {
  6975. png_read_image()
  6976. ; return 0; }
  6977. EOF
  6978. if { (eval echo configure:8420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  6979. rm -rf conftest*
  6980. eval "ac_cv_lib_$ac_lib_var=yes"
  6981. else
  6982. echo "configure: failed program was:" >&5
  6983. cat conftest.$ac_ext >&5
  6984. rm -rf conftest*
  6985. eval "ac_cv_lib_$ac_lib_var=no"
  6986. fi
  6987. rm -f conftest*
  6988. LIBS="$ac_save_LIBS"
  6989. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  6990. echo "$ac_t""yes" 1>&6
  6991. PNGLIB="$PNGLIB -lpng $ZLIB $MATHLIB"
  6992. else
  6993. echo "$ac_t""no" 1>&6
  6994. LDFLAGS=${ac_save_ldflags}
  6995. { echo "configure: error: *** Unable to locate PNG library." 1>&2; exit 1; }
  6996. fi
  6997. LDFLAGS=${ac_save_ldflags}
  6998. fi # $USE_PNG
  6999. # Done checking PNG
  7000. # Enable PostgreSQL option
  7001. echo $ac_n "checking whether to use PostgreSQL""... $ac_c" 1>&6
  7002. echo "configure:8462: checking whether to use PostgreSQL" >&5
  7003. echo "$ac_t"""$with_postgres"" 1>&6
  7004. case "$with_postgres" in
  7005. "no") USE_POSTGRES= ;;
  7006. "yes") USE_POSTGRES="1" ;;
  7007. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  7008. esac
  7009. if test -n "$USE_POSTGRES"; then
  7010. cat >> confdefs.h <<\EOF
  7011. #define HAVE_POSTGRES 1
  7012. EOF
  7013. fi # $USE_POSTGRES
  7014. PQINCPATH=
  7015. PQLIBPATH=
  7016. PQLIB=
  7017. if test -n "$USE_POSTGRES"; then
  7018. # With PostgreSQL includes directory
  7019. echo $ac_n "checking for location of PostgreSQL includes""... $ac_c" 1>&6
  7020. echo "configure:8489: checking for location of PostgreSQL includes" >&5
  7021. case "$with_postgres_includes" in
  7022. y | ye | yes | n | no)
  7023. { echo "configure: error: *** You must supply a directory to --with-postgres-includes." 1>&2; exit 1; }
  7024. ;;
  7025. esac
  7026. echo "$ac_t""$with_postgres_includes" 1>&6
  7027. if test -n "$with_postgres_includes" ; then
  7028. for dir in $with_postgres_includes; do
  7029. if test -d "$dir"; then
  7030. PQINCPATH="$PQINCPATH -I$dir"
  7031. else
  7032. { echo "configure: error: *** PostgreSQL includes directory $dir does not exist." 1>&2; exit 1; }
  7033. fi
  7034. done
  7035. fi
  7036. ac_save_cppflags="$CPPFLAGS"
  7037. CPPFLAGS="$PQINCPATH $CPPFLAGS"
  7038. for ac_hdr in libpq-fe.h
  7039. do
  7040. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  7041. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  7042. echo "configure:8515: checking for $ac_hdr" >&5
  7043. cat > conftest.$ac_ext <<EOF
  7044. #line 8518 "configure"
  7045. #include "confdefs.h"
  7046. #include <$ac_hdr>
  7047. EOF
  7048. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  7049. { (eval echo configure:8523: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  7050. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  7051. if test -z "$ac_err"; then
  7052. rm -rf conftest*
  7053. eval "ac_cv_header_$ac_safe=yes"
  7054. else
  7055. echo "$ac_err" >&5
  7056. echo "configure: failed program was:" >&5
  7057. cat conftest.$ac_ext >&5
  7058. rm -rf conftest*
  7059. eval "ac_cv_header_$ac_safe=no"
  7060. fi
  7061. rm -f conftest*
  7062. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  7063. echo "$ac_t""yes" 1>&6
  7064. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  7065. cat >> confdefs.h <<EOF
  7066. #define $ac_tr_hdr 1
  7067. EOF
  7068. else
  7069. echo "$ac_t""no" 1>&6
  7070. { echo "configure: error: *** Unable to locate PostgreSQL includes." 1>&2; exit 1; }
  7071. fi
  7072. done
  7073. CPPFLAGS=$ac_save_cppflags
  7074. fi # $USE_POSTGRES
  7075. if test -n "$USE_POSTGRES"; then
  7076. # With PostgreSQL library directory
  7077. echo $ac_n "checking for location of PostgreSQL library""... $ac_c" 1>&6
  7078. echo "configure:8561: checking for location of PostgreSQL library" >&5
  7079. case "$with_postgres_libs" in
  7080. y | ye | yes | n | no)
  7081. { echo "configure: error: *** You must supply a directory to --with-postgres-libs." 1>&2; exit 1; }
  7082. ;;
  7083. esac
  7084. echo "$ac_t""$with_postgres_libs" 1>&6
  7085. if test -n "$with_postgres_libs"; then
  7086. for dir in $with_postgres_libs; do
  7087. if test -d "$dir"; then
  7088. PQLIBPATH="$PQLIBPATH -L$dir"
  7089. else
  7090. { echo "configure: error: *** PostgreSQL library directory $dir does not exist." 1>&2; exit 1; }
  7091. fi
  7092. done
  7093. fi
  7094. ac_save_ldflags="$LDFLAGS"
  7095. LDFLAGS="$PQLIBPATH $LDFLAGS"
  7096. echo $ac_n "checking for PQsetdbLogin in -lpq""... $ac_c" 1>&6
  7097. echo "configure:8590: checking for PQsetdbLogin in -lpq" >&5
  7098. ac_lib_var=`echo pq'_'PQsetdbLogin | sed 'y%./+-%__p_%'`
  7099. ac_save_LIBS="$LIBS"
  7100. LIBS="-lpq $LIBS"
  7101. cat > conftest.$ac_ext <<EOF
  7102. #line 8596 "configure"
  7103. #include "confdefs.h"
  7104. /* Override any gcc2 internal prototype to avoid an error. */
  7105. /* We use char because int might match the return type of a gcc2
  7106. builtin and then its argument prototype would still apply. */
  7107. char PQsetdbLogin();
  7108. int main() {
  7109. PQsetdbLogin()
  7110. ; return 0; }
  7111. EOF
  7112. if { (eval echo configure:8607: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7113. rm -rf conftest*
  7114. eval "ac_cv_lib_$ac_lib_var=yes"
  7115. else
  7116. echo "configure: failed program was:" >&5
  7117. cat conftest.$ac_ext >&5
  7118. rm -rf conftest*
  7119. eval "ac_cv_lib_$ac_lib_var=no"
  7120. fi
  7121. rm -f conftest*
  7122. LIBS="$ac_save_LIBS"
  7123. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7124. echo "$ac_t""yes" 1>&6
  7125. PQLIB="$PQLIB -lpq "
  7126. else
  7127. echo "$ac_t""no" 1>&6
  7128. echo $ac_n "checking for PQsetdbLogin in -lpq""... $ac_c" 1>&6
  7129. echo "configure:8626: checking for PQsetdbLogin in -lpq" >&5
  7130. ac_lib_var=`echo pq'_'PQsetdbLogin | sed 'y%./+-%__p_%'`
  7131. ac_save_LIBS="$LIBS"
  7132. LIBS="-lpq -lssl -lcrypto $LIBS"
  7133. cat > conftest.$ac_ext <<EOF
  7134. #line 8632 "configure"
  7135. #include "confdefs.h"
  7136. /* Override any gcc2 internal prototype to avoid an error. */
  7137. /* We use char because int might match the return type of a gcc2
  7138. builtin and then its argument prototype would still apply. */
  7139. char PQsetdbLogin();
  7140. int main() {
  7141. PQsetdbLogin()
  7142. ; return 0; }
  7143. EOF
  7144. if { (eval echo configure:8643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7145. rm -rf conftest*
  7146. eval "ac_cv_lib_$ac_lib_var=yes"
  7147. else
  7148. echo "configure: failed program was:" >&5
  7149. cat conftest.$ac_ext >&5
  7150. rm -rf conftest*
  7151. eval "ac_cv_lib_$ac_lib_var=no"
  7152. fi
  7153. rm -f conftest*
  7154. LIBS="$ac_save_LIBS"
  7155. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7156. echo "$ac_t""yes" 1>&6
  7157. PQLIB="$PQLIB -lpq -lssl -lcrypto"
  7158. else
  7159. echo "$ac_t""no" 1>&6
  7160. echo $ac_n "checking for PQsetdbLogin in -lpq""... $ac_c" 1>&6
  7161. echo "configure:8662: checking for PQsetdbLogin in -lpq" >&5
  7162. ac_lib_var=`echo pq'_'PQsetdbLogin | sed 'y%./+-%__p_%'`
  7163. ac_save_LIBS="$LIBS"
  7164. LIBS="-lpq -lcrypt $LIBS"
  7165. cat > conftest.$ac_ext <<EOF
  7166. #line 8668 "configure"
  7167. #include "confdefs.h"
  7168. /* Override any gcc2 internal prototype to avoid an error. */
  7169. /* We use char because int might match the return type of a gcc2
  7170. builtin and then its argument prototype would still apply. */
  7171. char PQsetdbLogin();
  7172. int main() {
  7173. PQsetdbLogin()
  7174. ; return 0; }
  7175. EOF
  7176. if { (eval echo configure:8679: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7177. rm -rf conftest*
  7178. eval "ac_cv_lib_$ac_lib_var=yes"
  7179. else
  7180. echo "configure: failed program was:" >&5
  7181. cat conftest.$ac_ext >&5
  7182. rm -rf conftest*
  7183. eval "ac_cv_lib_$ac_lib_var=no"
  7184. fi
  7185. rm -f conftest*
  7186. LIBS="$ac_save_LIBS"
  7187. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7188. echo "$ac_t""yes" 1>&6
  7189. PQLIB="$PQLIB -lpq -lcrypt"
  7190. else
  7191. echo "$ac_t""no" 1>&6
  7192. echo $ac_n "checking for PQsetdbLogin in -lpq""... $ac_c" 1>&6
  7193. echo "configure:8698: checking for PQsetdbLogin in -lpq" >&5
  7194. ac_lib_var=`echo pq'_'PQsetdbLogin | sed 'y%./+-%__p_%'`
  7195. ac_save_LIBS="$LIBS"
  7196. LIBS="-lpq -lcrypt -lssl -lcrypto $LIBS"
  7197. cat > conftest.$ac_ext <<EOF
  7198. #line 8704 "configure"
  7199. #include "confdefs.h"
  7200. /* Override any gcc2 internal prototype to avoid an error. */
  7201. /* We use char because int might match the return type of a gcc2
  7202. builtin and then its argument prototype would still apply. */
  7203. char PQsetdbLogin();
  7204. int main() {
  7205. PQsetdbLogin()
  7206. ; return 0; }
  7207. EOF
  7208. if { (eval echo configure:8715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7209. rm -rf conftest*
  7210. eval "ac_cv_lib_$ac_lib_var=yes"
  7211. else
  7212. echo "configure: failed program was:" >&5
  7213. cat conftest.$ac_ext >&5
  7214. rm -rf conftest*
  7215. eval "ac_cv_lib_$ac_lib_var=no"
  7216. fi
  7217. rm -f conftest*
  7218. LIBS="$ac_save_LIBS"
  7219. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7220. echo "$ac_t""yes" 1>&6
  7221. PQLIB="$PQLIB -lpq -lcrypt -lssl -lcrypto"
  7222. else
  7223. echo "$ac_t""no" 1>&6
  7224. LDFLAGS=${ac_save_ldflags}
  7225. { echo "configure: error: *** Unable to locate PostgreSQL library." 1>&2; exit 1; }
  7226. fi
  7227. fi
  7228. fi
  7229. fi
  7230. LDFLAGS=${ac_save_ldflags}
  7231. ac_save_ldflags="$LDFLAGS"
  7232. LDFLAGS="$LDFLAGS $PQLIBPATH"
  7233. echo $ac_n "checking for PQcmdTuples in -lpq""... $ac_c" 1>&6
  7234. echo "configure:8772: checking for PQcmdTuples in -lpq" >&5
  7235. ac_lib_var=`echo pq'_'PQcmdTuples | sed 'y%./+-%__p_%'`
  7236. ac_save_LIBS="$LIBS"
  7237. LIBS="-lpq $LIBS"
  7238. cat > conftest.$ac_ext <<EOF
  7239. #line 8778 "configure"
  7240. #include "confdefs.h"
  7241. /* Override any gcc2 internal prototype to avoid an error. */
  7242. /* We use char because int might match the return type of a gcc2
  7243. builtin and then its argument prototype would still apply. */
  7244. char PQcmdTuples();
  7245. int main() {
  7246. PQcmdTuples()
  7247. ; return 0; }
  7248. EOF
  7249. if { (eval echo configure:8789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7250. rm -rf conftest*
  7251. eval "ac_cv_lib_$ac_lib_var=yes"
  7252. else
  7253. echo "configure: failed program was:" >&5
  7254. cat conftest.$ac_ext >&5
  7255. rm -rf conftest*
  7256. eval "ac_cv_lib_$ac_lib_var=no"
  7257. fi
  7258. rm -f conftest*
  7259. LIBS="$ac_save_LIBS"
  7260. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7261. echo "$ac_t""yes" 1>&6
  7262. cat >> confdefs.h <<\EOF
  7263. #define HAVE_PQCMDTUPLES 1
  7264. EOF
  7265. else
  7266. echo "$ac_t""no" 1>&6
  7267. echo $ac_n "checking for PQcmdTuples in -lpq""... $ac_c" 1>&6
  7268. echo "configure:8811: checking for PQcmdTuples in -lpq" >&5
  7269. ac_lib_var=`echo pq'_'PQcmdTuples | sed 'y%./+-%__p_%'`
  7270. ac_save_LIBS="$LIBS"
  7271. LIBS="-lpq -lcrypt $LIBS"
  7272. cat > conftest.$ac_ext <<EOF
  7273. #line 8817 "configure"
  7274. #include "confdefs.h"
  7275. /* Override any gcc2 internal prototype to avoid an error. */
  7276. /* We use char because int might match the return type of a gcc2
  7277. builtin and then its argument prototype would still apply. */
  7278. char PQcmdTuples();
  7279. int main() {
  7280. PQcmdTuples()
  7281. ; return 0; }
  7282. EOF
  7283. if { (eval echo configure:8828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7284. rm -rf conftest*
  7285. eval "ac_cv_lib_$ac_lib_var=yes"
  7286. else
  7287. echo "configure: failed program was:" >&5
  7288. cat conftest.$ac_ext >&5
  7289. rm -rf conftest*
  7290. eval "ac_cv_lib_$ac_lib_var=no"
  7291. fi
  7292. rm -f conftest*
  7293. LIBS="$ac_save_LIBS"
  7294. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7295. echo "$ac_t""yes" 1>&6
  7296. cat >> confdefs.h <<\EOF
  7297. #define HAVE_PQCMDTUPLES 1
  7298. EOF
  7299. else
  7300. echo "$ac_t""no" 1>&6
  7301. fi
  7302. fi
  7303. LDFLAGS=${ac_save_ldflags}
  7304. fi # $USE_POSTGRES
  7305. # Done checking PostgreSQL
  7306. # Enable MySQL option
  7307. echo $ac_n "checking whether to use MySQL""... $ac_c" 1>&6
  7308. echo "configure:8871: checking whether to use MySQL" >&5
  7309. echo "$ac_t"""$with_mysql"" 1>&6
  7310. case "$with_mysql" in
  7311. "no") USE_MYSQL= ;;
  7312. "yes") USE_MYSQL="1" ;;
  7313. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  7314. esac
  7315. MYSQLINCPATH=
  7316. MYSQLLIBPATH=
  7317. MYSQLLIB=
  7318. if test -n "$USE_MYSQL"; then
  7319. # With MySQL includes directory
  7320. echo $ac_n "checking for location of MySQL includes""... $ac_c" 1>&6
  7321. echo "configure:8891: checking for location of MySQL includes" >&5
  7322. case "$with_mysql_includes" in
  7323. y | ye | yes | n | no)
  7324. { echo "configure: error: *** You must supply a directory to --with-mysql-includes." 1>&2; exit 1; }
  7325. ;;
  7326. esac
  7327. echo "$ac_t""$with_mysql_includes" 1>&6
  7328. if test -n "$with_mysql_includes" ; then
  7329. for dir in $with_mysql_includes; do
  7330. if test -d "$dir"; then
  7331. MYSQLINCPATH="$MYSQLINCPATH -I$dir"
  7332. else
  7333. { echo "configure: error: *** MySQL includes directory $dir does not exist." 1>&2; exit 1; }
  7334. fi
  7335. done
  7336. fi
  7337. ac_save_cppflags="$CPPFLAGS"
  7338. CPPFLAGS="$MYSQLINCPATH $CPPFLAGS"
  7339. for ac_hdr in mysql.h
  7340. do
  7341. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  7342. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  7343. echo "configure:8917: checking for $ac_hdr" >&5
  7344. cat > conftest.$ac_ext <<EOF
  7345. #line 8920 "configure"
  7346. #include "confdefs.h"
  7347. #include <$ac_hdr>
  7348. EOF
  7349. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  7350. { (eval echo configure:8925: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  7351. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  7352. if test -z "$ac_err"; then
  7353. rm -rf conftest*
  7354. eval "ac_cv_header_$ac_safe=yes"
  7355. else
  7356. echo "$ac_err" >&5
  7357. echo "configure: failed program was:" >&5
  7358. cat conftest.$ac_ext >&5
  7359. rm -rf conftest*
  7360. eval "ac_cv_header_$ac_safe=no"
  7361. fi
  7362. rm -f conftest*
  7363. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  7364. echo "$ac_t""yes" 1>&6
  7365. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  7366. cat >> confdefs.h <<EOF
  7367. #define $ac_tr_hdr 1
  7368. EOF
  7369. else
  7370. echo "$ac_t""no" 1>&6
  7371. { echo "configure: error: *** Unable to locate MySQL includes." 1>&2; exit 1; }
  7372. fi
  7373. done
  7374. CPPFLAGS=$ac_save_cppflags
  7375. fi # $USE_MYSQL
  7376. if test -n "$USE_MYSQL"; then
  7377. # With MySQL library directory
  7378. echo $ac_n "checking for location of MySQL library""... $ac_c" 1>&6
  7379. echo "configure:8962: checking for location of MySQL library" >&5
  7380. case "$with_mysql_libs" in
  7381. y | ye | yes | n | no)
  7382. { echo "configure: error: *** You must supply a directory to --with-mysql-libs." 1>&2; exit 1; }
  7383. ;;
  7384. esac
  7385. echo "$ac_t""$with_mysql_libs" 1>&6
  7386. if test -n "$with_mysql_libs"; then
  7387. for dir in $with_mysql_libs; do
  7388. if test -d "$dir"; then
  7389. MYSQLLIBPATH="$MYSQLLIBPATH -L$dir"
  7390. else
  7391. { echo "configure: error: *** MySQL library directory $dir does not exist." 1>&2; exit 1; }
  7392. fi
  7393. done
  7394. fi
  7395. ac_save_ldflags="$LDFLAGS"
  7396. LDFLAGS="$MYSQLLIBPATH $LDFLAGS"
  7397. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7398. echo "configure:8993: checking for mysql_query in -lmysqlclient" >&5
  7399. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7400. ac_save_LIBS="$LIBS"
  7401. LIBS="-lmysqlclient $LIBS"
  7402. cat > conftest.$ac_ext <<EOF
  7403. #line 8999 "configure"
  7404. #include "confdefs.h"
  7405. /* Override any gcc2 internal prototype to avoid an error. */
  7406. /* We use char because int might match the return type of a gcc2
  7407. builtin and then its argument prototype would still apply. */
  7408. char mysql_query();
  7409. int main() {
  7410. mysql_query()
  7411. ; return 0; }
  7412. EOF
  7413. if { (eval echo configure:9010: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7414. rm -rf conftest*
  7415. eval "ac_cv_lib_$ac_lib_var=yes"
  7416. else
  7417. echo "configure: failed program was:" >&5
  7418. cat conftest.$ac_ext >&5
  7419. rm -rf conftest*
  7420. eval "ac_cv_lib_$ac_lib_var=no"
  7421. fi
  7422. rm -f conftest*
  7423. LIBS="$ac_save_LIBS"
  7424. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7425. echo "$ac_t""yes" 1>&6
  7426. MYSQLLIB="$MYSQLLIB -lmysqlclient "
  7427. else
  7428. echo "$ac_t""no" 1>&6
  7429. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7430. echo "configure:9029: checking for mysql_query in -lmysqlclient" >&5
  7431. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7432. ac_save_LIBS="$LIBS"
  7433. LIBS="-lmysqlclient $MATHLIB $LIBS"
  7434. cat > conftest.$ac_ext <<EOF
  7435. #line 9035 "configure"
  7436. #include "confdefs.h"
  7437. /* Override any gcc2 internal prototype to avoid an error. */
  7438. /* We use char because int might match the return type of a gcc2
  7439. builtin and then its argument prototype would still apply. */
  7440. char mysql_query();
  7441. int main() {
  7442. mysql_query()
  7443. ; return 0; }
  7444. EOF
  7445. if { (eval echo configure:9046: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7446. rm -rf conftest*
  7447. eval "ac_cv_lib_$ac_lib_var=yes"
  7448. else
  7449. echo "configure: failed program was:" >&5
  7450. cat conftest.$ac_ext >&5
  7451. rm -rf conftest*
  7452. eval "ac_cv_lib_$ac_lib_var=no"
  7453. fi
  7454. rm -f conftest*
  7455. LIBS="$ac_save_LIBS"
  7456. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7457. echo "$ac_t""yes" 1>&6
  7458. MYSQLLIB="$MYSQLLIB -lmysqlclient $MATHLIB"
  7459. else
  7460. echo "$ac_t""no" 1>&6
  7461. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7462. echo "configure:9065: checking for mysql_query in -lmysqlclient" >&5
  7463. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7464. ac_save_LIBS="$LIBS"
  7465. LIBS="-lmysqlclient $SOCKLIB $LIBS"
  7466. cat > conftest.$ac_ext <<EOF
  7467. #line 9071 "configure"
  7468. #include "confdefs.h"
  7469. /* Override any gcc2 internal prototype to avoid an error. */
  7470. /* We use char because int might match the return type of a gcc2
  7471. builtin and then its argument prototype would still apply. */
  7472. char mysql_query();
  7473. int main() {
  7474. mysql_query()
  7475. ; return 0; }
  7476. EOF
  7477. if { (eval echo configure:9082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7478. rm -rf conftest*
  7479. eval "ac_cv_lib_$ac_lib_var=yes"
  7480. else
  7481. echo "configure: failed program was:" >&5
  7482. cat conftest.$ac_ext >&5
  7483. rm -rf conftest*
  7484. eval "ac_cv_lib_$ac_lib_var=no"
  7485. fi
  7486. rm -f conftest*
  7487. LIBS="$ac_save_LIBS"
  7488. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7489. echo "$ac_t""yes" 1>&6
  7490. MYSQLLIB="$MYSQLLIB -lmysqlclient $SOCKLIB"
  7491. else
  7492. echo "$ac_t""no" 1>&6
  7493. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7494. echo "configure:9101: checking for mysql_query in -lmysqlclient" >&5
  7495. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7496. ac_save_LIBS="$LIBS"
  7497. LIBS="-lmysqlclient $SOCKLIB $MATHLIB $LIBS"
  7498. cat > conftest.$ac_ext <<EOF
  7499. #line 9107 "configure"
  7500. #include "confdefs.h"
  7501. /* Override any gcc2 internal prototype to avoid an error. */
  7502. /* We use char because int might match the return type of a gcc2
  7503. builtin and then its argument prototype would still apply. */
  7504. char mysql_query();
  7505. int main() {
  7506. mysql_query()
  7507. ; return 0; }
  7508. EOF
  7509. if { (eval echo configure:9118: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7510. rm -rf conftest*
  7511. eval "ac_cv_lib_$ac_lib_var=yes"
  7512. else
  7513. echo "configure: failed program was:" >&5
  7514. cat conftest.$ac_ext >&5
  7515. rm -rf conftest*
  7516. eval "ac_cv_lib_$ac_lib_var=no"
  7517. fi
  7518. rm -f conftest*
  7519. LIBS="$ac_save_LIBS"
  7520. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7521. echo "$ac_t""yes" 1>&6
  7522. MYSQLLIB="$MYSQLLIB -lmysqlclient $SOCKLIB $MATHLIB"
  7523. else
  7524. echo "$ac_t""no" 1>&6
  7525. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7526. echo "configure:9137: checking for mysql_query in -lmysqlclient" >&5
  7527. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7528. ac_save_LIBS="$LIBS"
  7529. LIBS="-lmysqlclient $ZLIB $LIBS"
  7530. cat > conftest.$ac_ext <<EOF
  7531. #line 9143 "configure"
  7532. #include "confdefs.h"
  7533. /* Override any gcc2 internal prototype to avoid an error. */
  7534. /* We use char because int might match the return type of a gcc2
  7535. builtin and then its argument prototype would still apply. */
  7536. char mysql_query();
  7537. int main() {
  7538. mysql_query()
  7539. ; return 0; }
  7540. EOF
  7541. if { (eval echo configure:9154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7542. rm -rf conftest*
  7543. eval "ac_cv_lib_$ac_lib_var=yes"
  7544. else
  7545. echo "configure: failed program was:" >&5
  7546. cat conftest.$ac_ext >&5
  7547. rm -rf conftest*
  7548. eval "ac_cv_lib_$ac_lib_var=no"
  7549. fi
  7550. rm -f conftest*
  7551. LIBS="$ac_save_LIBS"
  7552. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7553. echo "$ac_t""yes" 1>&6
  7554. MYSQLLIB="$MYSQLLIB -lmysqlclient $ZLIB"
  7555. else
  7556. echo "$ac_t""no" 1>&6
  7557. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7558. echo "configure:9173: checking for mysql_query in -lmysqlclient" >&5
  7559. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7560. ac_save_LIBS="$LIBS"
  7561. LIBS="-lmysqlclient $ZLIB $MATHLIB $LIBS"
  7562. cat > conftest.$ac_ext <<EOF
  7563. #line 9179 "configure"
  7564. #include "confdefs.h"
  7565. /* Override any gcc2 internal prototype to avoid an error. */
  7566. /* We use char because int might match the return type of a gcc2
  7567. builtin and then its argument prototype would still apply. */
  7568. char mysql_query();
  7569. int main() {
  7570. mysql_query()
  7571. ; return 0; }
  7572. EOF
  7573. if { (eval echo configure:9190: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7574. rm -rf conftest*
  7575. eval "ac_cv_lib_$ac_lib_var=yes"
  7576. else
  7577. echo "configure: failed program was:" >&5
  7578. cat conftest.$ac_ext >&5
  7579. rm -rf conftest*
  7580. eval "ac_cv_lib_$ac_lib_var=no"
  7581. fi
  7582. rm -f conftest*
  7583. LIBS="$ac_save_LIBS"
  7584. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7585. echo "$ac_t""yes" 1>&6
  7586. MYSQLLIB="$MYSQLLIB -lmysqlclient $ZLIB $MATHLIB"
  7587. else
  7588. echo "$ac_t""no" 1>&6
  7589. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7590. echo "configure:9209: checking for mysql_query in -lmysqlclient" >&5
  7591. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7592. ac_save_LIBS="$LIBS"
  7593. LIBS="-lmysqlclient $ZLIB $SOCKLIB $LIBS"
  7594. cat > conftest.$ac_ext <<EOF
  7595. #line 9215 "configure"
  7596. #include "confdefs.h"
  7597. /* Override any gcc2 internal prototype to avoid an error. */
  7598. /* We use char because int might match the return type of a gcc2
  7599. builtin and then its argument prototype would still apply. */
  7600. char mysql_query();
  7601. int main() {
  7602. mysql_query()
  7603. ; return 0; }
  7604. EOF
  7605. if { (eval echo configure:9226: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7606. rm -rf conftest*
  7607. eval "ac_cv_lib_$ac_lib_var=yes"
  7608. else
  7609. echo "configure: failed program was:" >&5
  7610. cat conftest.$ac_ext >&5
  7611. rm -rf conftest*
  7612. eval "ac_cv_lib_$ac_lib_var=no"
  7613. fi
  7614. rm -f conftest*
  7615. LIBS="$ac_save_LIBS"
  7616. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7617. echo "$ac_t""yes" 1>&6
  7618. MYSQLLIB="$MYSQLLIB -lmysqlclient $ZLIB $SOCKLIB"
  7619. else
  7620. echo "$ac_t""no" 1>&6
  7621. echo $ac_n "checking for mysql_query in -lmysqlclient""... $ac_c" 1>&6
  7622. echo "configure:9245: checking for mysql_query in -lmysqlclient" >&5
  7623. ac_lib_var=`echo mysqlclient'_'mysql_query | sed 'y%./+-%__p_%'`
  7624. ac_save_LIBS="$LIBS"
  7625. LIBS="-lmysqlclient $ZLIB $SOCKLIB $MATHLIB $LIBS"
  7626. cat > conftest.$ac_ext <<EOF
  7627. #line 9251 "configure"
  7628. #include "confdefs.h"
  7629. /* Override any gcc2 internal prototype to avoid an error. */
  7630. /* We use char because int might match the return type of a gcc2
  7631. builtin and then its argument prototype would still apply. */
  7632. char mysql_query();
  7633. int main() {
  7634. mysql_query()
  7635. ; return 0; }
  7636. EOF
  7637. if { (eval echo configure:9262: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7638. rm -rf conftest*
  7639. eval "ac_cv_lib_$ac_lib_var=yes"
  7640. else
  7641. echo "configure: failed program was:" >&5
  7642. cat conftest.$ac_ext >&5
  7643. rm -rf conftest*
  7644. eval "ac_cv_lib_$ac_lib_var=no"
  7645. fi
  7646. rm -f conftest*
  7647. LIBS="$ac_save_LIBS"
  7648. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7649. echo "$ac_t""yes" 1>&6
  7650. MYSQLLIB="$MYSQLLIB -lmysqlclient $ZLIB $SOCKLIB $MATHLIB"
  7651. else
  7652. echo "$ac_t""no" 1>&6
  7653. LDFLAGS=${ac_save_ldflags}
  7654. { echo "configure: error: *** Unable to locate MySQL library." 1>&2; exit 1; }
  7655. fi
  7656. fi
  7657. fi
  7658. fi
  7659. fi
  7660. fi
  7661. fi
  7662. fi
  7663. LDFLAGS=${ac_save_ldflags}
  7664. # Check for libmysqld (for embeded version of the driver)
  7665. # Extract the first word of "mysql_config", so it can be a program name with args.
  7666. set dummy mysql_config; ac_word=$2
  7667. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  7668. echo "configure:9352: checking for $ac_word" >&5
  7669. case "$MYSQLD_CONFIG" in
  7670. /*)
  7671. ac_cv_path_MYSQLD_CONFIG="$MYSQLD_CONFIG" # Let the user override the test with a path.
  7672. ;;
  7673. ?:/*)
  7674. ac_cv_path_MYSQLD_CONFIG="$MYSQLD_CONFIG" # Let the user override the test with a dos path.
  7675. ;;
  7676. *)
  7677. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  7678. ac_dummy="$PATH"
  7679. for ac_dir in $ac_dummy; do
  7680. test -z "$ac_dir" && ac_dir=.
  7681. if test -f $ac_dir/$ac_word; then
  7682. ac_cv_path_MYSQLD_CONFIG="$ac_dir/$ac_word"
  7683. break
  7684. fi
  7685. done
  7686. IFS="$ac_save_ifs"
  7687. test -z "$ac_cv_path_MYSQLD_CONFIG" && ac_cv_path_MYSQLD_CONFIG="no"
  7688. ;;
  7689. esac
  7690. MYSQLD_CONFIG="$ac_cv_path_MYSQLD_CONFIG"
  7691. if test -n "$MYSQLD_CONFIG"; then
  7692. echo "$ac_t""$MYSQLD_CONFIG" 1>&6
  7693. else
  7694. echo "$ac_t""no" 1>&6
  7695. fi
  7696. if test "$MYSQLD_CONFIG" = "no" ; then
  7697. { echo "configure: error: *** couldn't find mysql_config" 1>&2; exit 1; }
  7698. fi
  7699. if test "$MYSQLD_CONFIG" != "" ; then
  7700. ac_ext=C
  7701. # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  7702. ac_cpp='$CXXCPP $CPPFLAGS'
  7703. ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  7704. ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  7705. cross_compiling=$ac_cv_prog_cxx_cross
  7706. ac_save_libs="$LIBS"
  7707. MYSQLDLIB=`"$MYSQLD_CONFIG" --libmysqld-libs`
  7708. LIBS="$MYSQLDLIB $LIBS"
  7709. echo $ac_n "checking for mysql_server_init""... $ac_c" 1>&6
  7710. echo "configure:9401: checking for mysql_server_init" >&5
  7711. cat > conftest.$ac_ext <<EOF
  7712. #line 9404 "configure"
  7713. #include "confdefs.h"
  7714. /* System header to define __stub macros and hopefully few prototypes,
  7715. which can conflict with char mysql_server_init(); below. */
  7716. #include <assert.h>
  7717. /* Override any gcc2 internal prototype to avoid an error. */
  7718. #ifdef __cplusplus
  7719. extern "C"
  7720. #endif
  7721. /* We use char because int might match the return type of a gcc2
  7722. builtin and then its argument prototype would still apply. */
  7723. char mysql_server_init();
  7724. int main() {
  7725. /* The GNU C library defines this for functions which it implements
  7726. to always fail with ENOSYS. Some functions are actually named
  7727. something starting with __ and the normal name is an alias. */
  7728. #if defined (__stub_mysql_server_init) || defined (__stub___mysql_server_init)
  7729. choke me
  7730. #else
  7731. mysql_server_init();
  7732. #endif
  7733. ; return 0; }
  7734. EOF
  7735. if { (eval echo configure:9430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7736. rm -rf conftest*
  7737. eval "ac_cv_func_mysql_server_init=yes"
  7738. else
  7739. echo "configure: failed program was:" >&5
  7740. cat conftest.$ac_ext >&5
  7741. rm -rf conftest*
  7742. eval "ac_cv_func_mysql_server_init=no"
  7743. fi
  7744. rm -f conftest*
  7745. if eval "test \"`echo '$ac_cv_func_'mysql_server_init`\" = yes"; then
  7746. echo "$ac_t""yes" 1>&6
  7747. :
  7748. else
  7749. echo "$ac_t""no" 1>&6
  7750. MYSQLDLIB="";
  7751. echo "configure: warning: libmysqld not found" 1>&2
  7752. fi
  7753. LIBS=$ac_save_libs
  7754. ac_ext=c
  7755. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  7756. ac_cpp='$CPP $CPPFLAGS'
  7757. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  7758. ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  7759. cross_compiling=$ac_cv_prog_cc_cross
  7760. ac_ext=c
  7761. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  7762. ac_cpp='$CPP $CPPFLAGS'
  7763. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  7764. ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  7765. cross_compiling=$ac_cv_prog_cc_cross
  7766. fi
  7767. fi # $USE_MYSQL
  7768. # Done checking MySQL
  7769. # Enable SQLite option
  7770. echo $ac_n "checking whether to use SQLite""... $ac_c" 1>&6
  7771. echo "configure:9482: checking whether to use SQLite" >&5
  7772. echo "$ac_t"""$with_sqlite"" 1>&6
  7773. case "$with_sqlite" in
  7774. "no") USE_SQLITE= ;;
  7775. "yes") USE_SQLITE="1" ;;
  7776. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  7777. esac
  7778. SQLITEINCPATH=
  7779. SQLITELIBPATH=
  7780. SQLITELIB=
  7781. if test -n "$USE_SQLITE"; then
  7782. # With SQLite includes directory
  7783. echo $ac_n "checking for location of SQLite includes""... $ac_c" 1>&6
  7784. echo "configure:9502: checking for location of SQLite includes" >&5
  7785. case "$with_sqlite_includes" in
  7786. y | ye | yes | n | no)
  7787. { echo "configure: error: *** You must supply a directory to --with-sqlite-includes." 1>&2; exit 1; }
  7788. ;;
  7789. esac
  7790. echo "$ac_t""$with_sqlite_includes" 1>&6
  7791. if test -n "$with_sqlite_includes" ; then
  7792. for dir in $with_sqlite_includes; do
  7793. if test -d "$dir"; then
  7794. SQLITEINCPATH="$SQLITEINCPATH -I$dir"
  7795. else
  7796. { echo "configure: error: *** SQLite includes directory $dir does not exist." 1>&2; exit 1; }
  7797. fi
  7798. done
  7799. fi
  7800. ac_save_cppflags="$CPPFLAGS"
  7801. CPPFLAGS="$SQLITEINCPATH $CPPFLAGS"
  7802. for ac_hdr in sqlite3.h
  7803. do
  7804. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  7805. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  7806. echo "configure:9528: checking for $ac_hdr" >&5
  7807. cat > conftest.$ac_ext <<EOF
  7808. #line 9531 "configure"
  7809. #include "confdefs.h"
  7810. #include <$ac_hdr>
  7811. EOF
  7812. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  7813. { (eval echo configure:9536: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  7814. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  7815. if test -z "$ac_err"; then
  7816. rm -rf conftest*
  7817. eval "ac_cv_header_$ac_safe=yes"
  7818. else
  7819. echo "$ac_err" >&5
  7820. echo "configure: failed program was:" >&5
  7821. cat conftest.$ac_ext >&5
  7822. rm -rf conftest*
  7823. eval "ac_cv_header_$ac_safe=no"
  7824. fi
  7825. rm -f conftest*
  7826. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  7827. echo "$ac_t""yes" 1>&6
  7828. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  7829. cat >> confdefs.h <<EOF
  7830. #define $ac_tr_hdr 1
  7831. EOF
  7832. else
  7833. echo "$ac_t""no" 1>&6
  7834. { echo "configure: error: *** Unable to locate SQLite includes." 1>&2; exit 1; }
  7835. fi
  7836. done
  7837. CPPFLAGS=$ac_save_cppflags
  7838. cat >> confdefs.h <<\EOF
  7839. #define HAVE_SQLITE 1
  7840. EOF
  7841. fi # $USE_SQLITE
  7842. if test -n "$USE_SQLITE"; then
  7843. # With SQLite library directory
  7844. echo $ac_n "checking for location of SQLite library""... $ac_c" 1>&6
  7845. echo "configure:9579: checking for location of SQLite library" >&5
  7846. case "$with_sqlite_libs" in
  7847. y | ye | yes | n | no)
  7848. { echo "configure: error: *** You must supply a directory to --with-sqlite-libs." 1>&2; exit 1; }
  7849. ;;
  7850. esac
  7851. echo "$ac_t""$with_sqlite_libs" 1>&6
  7852. if test -n "$with_sqlite_libs"; then
  7853. for dir in $with_sqlite_libs; do
  7854. if test -d "$dir"; then
  7855. SQLITELIBPATH="$SQLITELIBPATH -L$dir"
  7856. else
  7857. { echo "configure: error: *** SQLite library directory $dir does not exist." 1>&2; exit 1; }
  7858. fi
  7859. done
  7860. fi
  7861. ac_save_ldflags="$LDFLAGS"
  7862. LDFLAGS="$SQLITELIBPATH $LDFLAGS"
  7863. echo $ac_n "checking for sqlite3_open in -lsqlite3""... $ac_c" 1>&6
  7864. echo "configure:9606: checking for sqlite3_open in -lsqlite3" >&5
  7865. ac_lib_var=`echo sqlite3'_'sqlite3_open | sed 'y%./+-%__p_%'`
  7866. ac_save_LIBS="$LIBS"
  7867. LIBS="-lsqlite3 $LIBS"
  7868. cat > conftest.$ac_ext <<EOF
  7869. #line 9612 "configure"
  7870. #include "confdefs.h"
  7871. /* Override any gcc2 internal prototype to avoid an error. */
  7872. /* We use char because int might match the return type of a gcc2
  7873. builtin and then its argument prototype would still apply. */
  7874. char sqlite3_open();
  7875. int main() {
  7876. sqlite3_open()
  7877. ; return 0; }
  7878. EOF
  7879. if { (eval echo configure:9623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7880. rm -rf conftest*
  7881. eval "ac_cv_lib_$ac_lib_var=yes"
  7882. else
  7883. echo "configure: failed program was:" >&5
  7884. cat conftest.$ac_ext >&5
  7885. rm -rf conftest*
  7886. eval "ac_cv_lib_$ac_lib_var=no"
  7887. fi
  7888. rm -f conftest*
  7889. LIBS="$ac_save_LIBS"
  7890. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7891. echo "$ac_t""yes" 1>&6
  7892. SQLITELIB="$SQLITELIB -lsqlite3 "
  7893. else
  7894. echo "$ac_t""no" 1>&6
  7895. echo $ac_n "checking for sqlite3_open in -lsqlite3""... $ac_c" 1>&6
  7896. echo "configure:9642: checking for sqlite3_open in -lsqlite3" >&5
  7897. ac_lib_var=`echo sqlite3'_'sqlite3_open | sed 'y%./+-%__p_%'`
  7898. ac_save_LIBS="$LIBS"
  7899. LIBS="-lsqlite3 $MATHLIB $LIBS"
  7900. cat > conftest.$ac_ext <<EOF
  7901. #line 9648 "configure"
  7902. #include "confdefs.h"
  7903. /* Override any gcc2 internal prototype to avoid an error. */
  7904. /* We use char because int might match the return type of a gcc2
  7905. builtin and then its argument prototype would still apply. */
  7906. char sqlite3_open();
  7907. int main() {
  7908. sqlite3_open()
  7909. ; return 0; }
  7910. EOF
  7911. if { (eval echo configure:9659: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  7912. rm -rf conftest*
  7913. eval "ac_cv_lib_$ac_lib_var=yes"
  7914. else
  7915. echo "configure: failed program was:" >&5
  7916. cat conftest.$ac_ext >&5
  7917. rm -rf conftest*
  7918. eval "ac_cv_lib_$ac_lib_var=no"
  7919. fi
  7920. rm -f conftest*
  7921. LIBS="$ac_save_LIBS"
  7922. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  7923. echo "$ac_t""yes" 1>&6
  7924. SQLITELIB="$SQLITELIB -lsqlite3 $MATHLIB"
  7925. else
  7926. echo "$ac_t""no" 1>&6
  7927. LDFLAGS=${ac_save_ldflags}
  7928. { echo "configure: error: *** Unable to locate SQLite library." 1>&2; exit 1; }
  7929. fi
  7930. fi
  7931. LDFLAGS=${ac_save_ldflags}
  7932. fi # $USE_SQLITE
  7933. # Done checking SQLite
  7934. # Enable FFMPEG option
  7935. echo $ac_n "checking whether to use FFMPEG""... $ac_c" 1>&6
  7936. echo "configure:9712: checking whether to use FFMPEG" >&5
  7937. echo "$ac_t"""$with_ffmpeg"" 1>&6
  7938. case "$with_ffmpeg" in
  7939. "no") USE_FFMPEG= ;;
  7940. "yes") USE_FFMPEG="1" ;;
  7941. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  7942. esac
  7943. FFMPEGINCPATH=
  7944. FFMPEGLIBPATH=
  7945. FFMPEGLIB=
  7946. if test -n "$USE_FFMPEG"; then
  7947. # With FFMPEG includes directory
  7948. echo $ac_n "checking for location of FFMPEG includes""... $ac_c" 1>&6
  7949. echo "configure:9732: checking for location of FFMPEG includes" >&5
  7950. case "$with_ffmpeg_includes" in
  7951. y | ye | yes | n | no)
  7952. { echo "configure: error: *** You must supply a directory to --with-ffmpeg-includes." 1>&2; exit 1; }
  7953. ;;
  7954. esac
  7955. echo "$ac_t""$with_ffmpeg_includes" 1>&6
  7956. if test -n "$with_ffmpeg_includes" ; then
  7957. for dir in $with_ffmpeg_includes; do
  7958. if test -d "$dir"; then
  7959. FFMPEGINCPATH="$FFMPEGINCPATH -I$dir"
  7960. else
  7961. { echo "configure: error: *** FFMPEG includes directory $dir does not exist." 1>&2; exit 1; }
  7962. fi
  7963. done
  7964. fi
  7965. ac_save_cppflags="$CPPFLAGS"
  7966. CPPFLAGS="$FFMPEGINCPATH $CPPFLAGS"
  7967. for ac_hdr in avcodec.h
  7968. do
  7969. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  7970. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  7971. echo "configure:9758: checking for $ac_hdr" >&5
  7972. cat > conftest.$ac_ext <<EOF
  7973. #line 9761 "configure"
  7974. #include "confdefs.h"
  7975. #include <$ac_hdr>
  7976. EOF
  7977. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  7978. { (eval echo configure:9766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  7979. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  7980. if test -z "$ac_err"; then
  7981. rm -rf conftest*
  7982. eval "ac_cv_header_$ac_safe=yes"
  7983. else
  7984. echo "$ac_err" >&5
  7985. echo "configure: failed program was:" >&5
  7986. cat conftest.$ac_ext >&5
  7987. rm -rf conftest*
  7988. eval "ac_cv_header_$ac_safe=no"
  7989. fi
  7990. rm -f conftest*
  7991. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  7992. echo "$ac_t""yes" 1>&6
  7993. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  7994. cat >> confdefs.h <<EOF
  7995. #define $ac_tr_hdr 1
  7996. EOF
  7997. else
  7998. echo "$ac_t""no" 1>&6
  7999. { echo "configure: error: *** Unable to locate FFMPEG includes." 1>&2; exit 1; }
  8000. fi
  8001. done
  8002. CPPFLAGS=$ac_save_cppflags
  8003. ac_save_cppflags="$CPPFLAGS"
  8004. CPPFLAGS="$FFMPEGINCPATH $CPPFLAGS"
  8005. for ac_hdr in avformat.h
  8006. do
  8007. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  8008. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  8009. echo "configure:9802: checking for $ac_hdr" >&5
  8010. cat > conftest.$ac_ext <<EOF
  8011. #line 9805 "configure"
  8012. #include "confdefs.h"
  8013. #include <$ac_hdr>
  8014. EOF
  8015. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  8016. { (eval echo configure:9810: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  8017. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  8018. if test -z "$ac_err"; then
  8019. rm -rf conftest*
  8020. eval "ac_cv_header_$ac_safe=yes"
  8021. else
  8022. echo "$ac_err" >&5
  8023. echo "configure: failed program was:" >&5
  8024. cat conftest.$ac_ext >&5
  8025. rm -rf conftest*
  8026. eval "ac_cv_header_$ac_safe=no"
  8027. fi
  8028. rm -f conftest*
  8029. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  8030. echo "$ac_t""yes" 1>&6
  8031. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  8032. cat >> confdefs.h <<EOF
  8033. #define $ac_tr_hdr 1
  8034. EOF
  8035. else
  8036. echo "$ac_t""no" 1>&6
  8037. { echo "configure: error: *** Unable to locate FFMPEG includes." 1>&2; exit 1; }
  8038. fi
  8039. done
  8040. CPPFLAGS=$ac_save_cppflags
  8041. ac_save_cppflags="$CPPFLAGS"
  8042. CPPFLAGS="$FFMPEGINCPATH $CPPFLAGS"
  8043. for ac_hdr in swscale.h
  8044. do
  8045. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  8046. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  8047. echo "configure:9846: checking for $ac_hdr" >&5
  8048. cat > conftest.$ac_ext <<EOF
  8049. #line 9849 "configure"
  8050. #include "confdefs.h"
  8051. #include <$ac_hdr>
  8052. EOF
  8053. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  8054. { (eval echo configure:9854: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  8055. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  8056. if test -z "$ac_err"; then
  8057. rm -rf conftest*
  8058. eval "ac_cv_header_$ac_safe=yes"
  8059. else
  8060. echo "$ac_err" >&5
  8061. echo "configure: failed program was:" >&5
  8062. cat conftest.$ac_ext >&5
  8063. rm -rf conftest*
  8064. eval "ac_cv_header_$ac_safe=no"
  8065. fi
  8066. rm -f conftest*
  8067. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  8068. echo "$ac_t""yes" 1>&6
  8069. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  8070. cat >> confdefs.h <<EOF
  8071. #define $ac_tr_hdr 1
  8072. EOF
  8073. else
  8074. echo "$ac_t""no" 1>&6
  8075. { echo "configure: error: *** Unable to locate FFMPEG includes." 1>&2; exit 1; }
  8076. fi
  8077. done
  8078. CPPFLAGS=$ac_save_cppflags
  8079. cat >> confdefs.h <<\EOF
  8080. #define HAVE_FFMPEG 1
  8081. EOF
  8082. fi # $USE_FFMPEG
  8083. if test -n "$USE_FFMPEG"; then
  8084. # With FFMPEG library directory
  8085. echo $ac_n "checking for location of FFMPEG library""... $ac_c" 1>&6
  8086. echo "configure:9897: checking for location of FFMPEG library" >&5
  8087. case "$with_ffmpeg_libs" in
  8088. y | ye | yes | n | no)
  8089. { echo "configure: error: *** You must supply a directory to --with-ffmpeg-libs." 1>&2; exit 1; }
  8090. ;;
  8091. esac
  8092. echo "$ac_t""$with_ffmpeg_libs" 1>&6
  8093. if test -n "$with_ffmpeg_libs"; then
  8094. for dir in $with_ffmpeg_libs; do
  8095. if test -d "$dir"; then
  8096. FFMPEGLIBPATH="$FFMPEGLIBPATH -L$dir"
  8097. else
  8098. { echo "configure: error: *** FFMPEG library directory $dir does not exist." 1>&2; exit 1; }
  8099. fi
  8100. done
  8101. fi
  8102. ac_save_ldflags="$LDFLAGS"
  8103. LDFLAGS="$FFMPEGLIBPATH $LDFLAGS"
  8104. echo $ac_n "checking for av_free in -lavutil""... $ac_c" 1>&6
  8105. echo "configure:9924: checking for av_free in -lavutil" >&5
  8106. ac_lib_var=`echo avutil'_'av_free | sed 'y%./+-%__p_%'`
  8107. ac_save_LIBS="$LIBS"
  8108. LIBS="-lavutil $LIBS"
  8109. cat > conftest.$ac_ext <<EOF
  8110. #line 9930 "configure"
  8111. #include "confdefs.h"
  8112. /* Override any gcc2 internal prototype to avoid an error. */
  8113. /* We use char because int might match the return type of a gcc2
  8114. builtin and then its argument prototype would still apply. */
  8115. char av_free();
  8116. int main() {
  8117. av_free()
  8118. ; return 0; }
  8119. EOF
  8120. if { (eval echo configure:9941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8121. rm -rf conftest*
  8122. eval "ac_cv_lib_$ac_lib_var=yes"
  8123. else
  8124. echo "configure: failed program was:" >&5
  8125. cat conftest.$ac_ext >&5
  8126. rm -rf conftest*
  8127. eval "ac_cv_lib_$ac_lib_var=no"
  8128. fi
  8129. rm -f conftest*
  8130. LIBS="$ac_save_LIBS"
  8131. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8132. echo "$ac_t""yes" 1>&6
  8133. FFMPEGLIB="$FFMPEGLIB -lavutil "
  8134. else
  8135. echo "$ac_t""no" 1>&6
  8136. echo $ac_n "checking for av_free in -lavutil""... $ac_c" 1>&6
  8137. echo "configure:9960: checking for av_free in -lavutil" >&5
  8138. ac_lib_var=`echo avutil'_'av_free | sed 'y%./+-%__p_%'`
  8139. ac_save_LIBS="$LIBS"
  8140. LIBS="-lavutil $MATHLIB $LIBS"
  8141. cat > conftest.$ac_ext <<EOF
  8142. #line 9966 "configure"
  8143. #include "confdefs.h"
  8144. /* Override any gcc2 internal prototype to avoid an error. */
  8145. /* We use char because int might match the return type of a gcc2
  8146. builtin and then its argument prototype would still apply. */
  8147. char av_free();
  8148. int main() {
  8149. av_free()
  8150. ; return 0; }
  8151. EOF
  8152. if { (eval echo configure:9977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8153. rm -rf conftest*
  8154. eval "ac_cv_lib_$ac_lib_var=yes"
  8155. else
  8156. echo "configure: failed program was:" >&5
  8157. cat conftest.$ac_ext >&5
  8158. rm -rf conftest*
  8159. eval "ac_cv_lib_$ac_lib_var=no"
  8160. fi
  8161. rm -f conftest*
  8162. LIBS="$ac_save_LIBS"
  8163. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8164. echo "$ac_t""yes" 1>&6
  8165. FFMPEGLIB="$FFMPEGLIB -lavutil $MATHLIB"
  8166. else
  8167. echo "$ac_t""no" 1>&6
  8168. LDFLAGS=${ac_save_ldflags}
  8169. { echo "configure: error: *** Unable to locate FFMPEG library." 1>&2; exit 1; }
  8170. fi
  8171. fi
  8172. LDFLAGS=${ac_save_ldflags}
  8173. ac_save_ldflags="$LDFLAGS"
  8174. LDFLAGS="$FFMPEGLIBPATH $LDFLAGS"
  8175. echo $ac_n "checking for avcodec_init in -lavcodec""... $ac_c" 1>&6
  8176. echo "configure:10022: checking for avcodec_init in -lavcodec" >&5
  8177. ac_lib_var=`echo avcodec'_'avcodec_init | sed 'y%./+-%__p_%'`
  8178. ac_save_LIBS="$LIBS"
  8179. LIBS="-lavcodec $FFMPEGLIB $LIBS"
  8180. cat > conftest.$ac_ext <<EOF
  8181. #line 10028 "configure"
  8182. #include "confdefs.h"
  8183. /* Override any gcc2 internal prototype to avoid an error. */
  8184. /* We use char because int might match the return type of a gcc2
  8185. builtin and then its argument prototype would still apply. */
  8186. char avcodec_init();
  8187. int main() {
  8188. avcodec_init()
  8189. ; return 0; }
  8190. EOF
  8191. if { (eval echo configure:10039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8192. rm -rf conftest*
  8193. eval "ac_cv_lib_$ac_lib_var=yes"
  8194. else
  8195. echo "configure: failed program was:" >&5
  8196. cat conftest.$ac_ext >&5
  8197. rm -rf conftest*
  8198. eval "ac_cv_lib_$ac_lib_var=no"
  8199. fi
  8200. rm -f conftest*
  8201. LIBS="$ac_save_LIBS"
  8202. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8203. echo "$ac_t""yes" 1>&6
  8204. FFMPEGLIB="$FFMPEGLIB -lavcodec "
  8205. else
  8206. echo "$ac_t""no" 1>&6
  8207. echo $ac_n "checking for avcodec_init in -lavcodec""... $ac_c" 1>&6
  8208. echo "configure:10058: checking for avcodec_init in -lavcodec" >&5
  8209. ac_lib_var=`echo avcodec'_'avcodec_init | sed 'y%./+-%__p_%'`
  8210. ac_save_LIBS="$LIBS"
  8211. LIBS="-lavcodec $FFMPEGLIB $MATHLIB $LIBS"
  8212. cat > conftest.$ac_ext <<EOF
  8213. #line 10064 "configure"
  8214. #include "confdefs.h"
  8215. /* Override any gcc2 internal prototype to avoid an error. */
  8216. /* We use char because int might match the return type of a gcc2
  8217. builtin and then its argument prototype would still apply. */
  8218. char avcodec_init();
  8219. int main() {
  8220. avcodec_init()
  8221. ; return 0; }
  8222. EOF
  8223. if { (eval echo configure:10075: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8224. rm -rf conftest*
  8225. eval "ac_cv_lib_$ac_lib_var=yes"
  8226. else
  8227. echo "configure: failed program was:" >&5
  8228. cat conftest.$ac_ext >&5
  8229. rm -rf conftest*
  8230. eval "ac_cv_lib_$ac_lib_var=no"
  8231. fi
  8232. rm -f conftest*
  8233. LIBS="$ac_save_LIBS"
  8234. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8235. echo "$ac_t""yes" 1>&6
  8236. FFMPEGLIB="$FFMPEGLIB -lavcodec $MATHLIB"
  8237. else
  8238. echo "$ac_t""no" 1>&6
  8239. LDFLAGS=${ac_save_ldflags}
  8240. { echo "configure: error: *** Unable to locate FFMPEG library." 1>&2; exit 1; }
  8241. fi
  8242. fi
  8243. LDFLAGS=${ac_save_ldflags}
  8244. ac_save_ldflags="$LDFLAGS"
  8245. LDFLAGS="$FFMPEGLIBPATH $LDFLAGS"
  8246. echo $ac_n "checking for av_set_parameters in -lavformat""... $ac_c" 1>&6
  8247. echo "configure:10120: checking for av_set_parameters in -lavformat" >&5
  8248. ac_lib_var=`echo avformat'_'av_set_parameters | sed 'y%./+-%__p_%'`
  8249. ac_save_LIBS="$LIBS"
  8250. LIBS="-lavformat $FFMPEGLIB $LIBS"
  8251. cat > conftest.$ac_ext <<EOF
  8252. #line 10126 "configure"
  8253. #include "confdefs.h"
  8254. /* Override any gcc2 internal prototype to avoid an error. */
  8255. /* We use char because int might match the return type of a gcc2
  8256. builtin and then its argument prototype would still apply. */
  8257. char av_set_parameters();
  8258. int main() {
  8259. av_set_parameters()
  8260. ; return 0; }
  8261. EOF
  8262. if { (eval echo configure:10137: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8263. rm -rf conftest*
  8264. eval "ac_cv_lib_$ac_lib_var=yes"
  8265. else
  8266. echo "configure: failed program was:" >&5
  8267. cat conftest.$ac_ext >&5
  8268. rm -rf conftest*
  8269. eval "ac_cv_lib_$ac_lib_var=no"
  8270. fi
  8271. rm -f conftest*
  8272. LIBS="$ac_save_LIBS"
  8273. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8274. echo "$ac_t""yes" 1>&6
  8275. FFMPEGLIB="$FFMPEGLIB -lavformat "
  8276. else
  8277. echo "$ac_t""no" 1>&6
  8278. echo $ac_n "checking for av_set_parameters in -lavformat""... $ac_c" 1>&6
  8279. echo "configure:10156: checking for av_set_parameters in -lavformat" >&5
  8280. ac_lib_var=`echo avformat'_'av_set_parameters | sed 'y%./+-%__p_%'`
  8281. ac_save_LIBS="$LIBS"
  8282. LIBS="-lavformat $FFMPEGLIB $MATHLIB $LIBS"
  8283. cat > conftest.$ac_ext <<EOF
  8284. #line 10162 "configure"
  8285. #include "confdefs.h"
  8286. /* Override any gcc2 internal prototype to avoid an error. */
  8287. /* We use char because int might match the return type of a gcc2
  8288. builtin and then its argument prototype would still apply. */
  8289. char av_set_parameters();
  8290. int main() {
  8291. av_set_parameters()
  8292. ; return 0; }
  8293. EOF
  8294. if { (eval echo configure:10173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8295. rm -rf conftest*
  8296. eval "ac_cv_lib_$ac_lib_var=yes"
  8297. else
  8298. echo "configure: failed program was:" >&5
  8299. cat conftest.$ac_ext >&5
  8300. rm -rf conftest*
  8301. eval "ac_cv_lib_$ac_lib_var=no"
  8302. fi
  8303. rm -f conftest*
  8304. LIBS="$ac_save_LIBS"
  8305. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8306. echo "$ac_t""yes" 1>&6
  8307. FFMPEGLIB="$FFMPEGLIB -lavformat $MATHLIB"
  8308. else
  8309. echo "$ac_t""no" 1>&6
  8310. LDFLAGS=${ac_save_ldflags}
  8311. { echo "configure: error: *** Unable to locate FFMPEG library." 1>&2; exit 1; }
  8312. fi
  8313. fi
  8314. LDFLAGS=${ac_save_ldflags}
  8315. fi # $USE_FFMPEG
  8316. # Done checking FFMPEG
  8317. # Enable OpenGL option
  8318. OPENGLINC=
  8319. OPENGLLIB=
  8320. OPENGLULIB=
  8321. USE_OPENGL=
  8322. OPENGL_X11=
  8323. OPENGL_AQUA=
  8324. OPENGL_WINDOWS=
  8325. echo $ac_n "checking whether to use OpenGL""... $ac_c" 1>&6
  8326. echo "configure:10232: checking whether to use OpenGL" >&5
  8327. echo "$ac_t"""$with_opengl"" 1>&6
  8328. case "$with_opengl" in
  8329. n|no)
  8330. OPENGL_TYPE=none
  8331. ;;
  8332. y|yes|x|x11|glx)
  8333. OPENGL_TYPE=X11
  8334. USE_OPENGL=1
  8335. OPENGL_X11=1
  8336. ;;
  8337. aqua|mac|osx|macosx|agl)
  8338. OPENGL_TYPE=Aqua
  8339. USE_OPENGL=1
  8340. OPENGL_AQUA=1
  8341. ;;
  8342. win|windows|mswin|wgl)
  8343. OPENGL_TYPE=Windows
  8344. USE_OPENGL=1
  8345. OPENGL_WINDOWS=1
  8346. ;;
  8347. *)
  8348. { echo "configure: error: *** Valid arguments for --with-opengl= are yes,no,x11,aqua,windows." 1>&2; exit 1; }
  8349. ;;
  8350. esac
  8351. if test -n "$USE_OPENGL" ; then
  8352. if test "$OPENGL_X11" = 1 ; then
  8353. # With OpenGL includes directory
  8354. echo $ac_n "checking for location of OpenGL includes""... $ac_c" 1>&6
  8355. echo "configure:10266: checking for location of OpenGL includes" >&5
  8356. case "$with_opengl_includes" in
  8357. y | ye | yes | n | no)
  8358. { echo "configure: error: *** You must supply a directory to --with-opengl-includes." 1>&2; exit 1; }
  8359. ;;
  8360. esac
  8361. echo "$ac_t""$with_opengl_includes" 1>&6
  8362. if test -n "$with_opengl_includes" ; then
  8363. for dir in $with_opengl_includes; do
  8364. if test -d "$dir"; then
  8365. OPENGLINC="$OPENGLINC -I$dir"
  8366. else
  8367. { echo "configure: error: *** OpenGL includes directory $dir does not exist." 1>&2; exit 1; }
  8368. fi
  8369. done
  8370. fi
  8371. ac_save_cppflags="$CPPFLAGS"
  8372. CPPFLAGS="$OPENGLINC $X_CFLAGS $CPPFLAGS"
  8373. for ac_hdr in GL/gl.h GL/glu.h
  8374. do
  8375. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  8376. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  8377. echo "configure:10292: checking for $ac_hdr" >&5
  8378. cat > conftest.$ac_ext <<EOF
  8379. #line 10295 "configure"
  8380. #include "confdefs.h"
  8381. #include <$ac_hdr>
  8382. EOF
  8383. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  8384. { (eval echo configure:10300: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  8385. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  8386. if test -z "$ac_err"; then
  8387. rm -rf conftest*
  8388. eval "ac_cv_header_$ac_safe=yes"
  8389. else
  8390. echo "$ac_err" >&5
  8391. echo "configure: failed program was:" >&5
  8392. cat conftest.$ac_ext >&5
  8393. rm -rf conftest*
  8394. eval "ac_cv_header_$ac_safe=no"
  8395. fi
  8396. rm -f conftest*
  8397. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  8398. echo "$ac_t""yes" 1>&6
  8399. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  8400. cat >> confdefs.h <<EOF
  8401. #define $ac_tr_hdr 1
  8402. EOF
  8403. else
  8404. echo "$ac_t""no" 1>&6
  8405. { echo "configure: error: *** Unable to locate OpenGL includes." 1>&2; exit 1; }
  8406. fi
  8407. done
  8408. CPPFLAGS=$ac_save_cppflags
  8409. # With OpenGL library directory
  8410. echo $ac_n "checking for location of OpenGL library""... $ac_c" 1>&6
  8411. echo "configure:10334: checking for location of OpenGL library" >&5
  8412. case "$with_opengl_libs" in
  8413. y | ye | yes | n | no)
  8414. { echo "configure: error: *** You must supply a directory to --with-opengl-libs." 1>&2; exit 1; }
  8415. ;;
  8416. esac
  8417. echo "$ac_t""$with_opengl_libs" 1>&6
  8418. if test -n "$with_opengl_libs"; then
  8419. for dir in $with_opengl_libs; do
  8420. if test -d "$dir"; then
  8421. OPENGL_LIB_PATH="$OPENGL_LIB_PATH -L$dir"
  8422. else
  8423. { echo "configure: error: *** OpenGL library directory $dir does not exist." 1>&2; exit 1; }
  8424. fi
  8425. done
  8426. fi
  8427. ac_save_ldflags="$LDFLAGS"
  8428. LDFLAGS="$OPENGL_LIB_PATH $LDFLAGS"
  8429. echo $ac_n "checking for glBegin in -lGL""... $ac_c" 1>&6
  8430. echo "configure:10363: checking for glBegin in -lGL" >&5
  8431. ac_lib_var=`echo GL'_'glBegin | sed 'y%./+-%__p_%'`
  8432. ac_save_LIBS="$LIBS"
  8433. LIBS="-lGL $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $MATHLIB $LIBS"
  8434. cat > conftest.$ac_ext <<EOF
  8435. #line 10369 "configure"
  8436. #include "confdefs.h"
  8437. /* Override any gcc2 internal prototype to avoid an error. */
  8438. /* We use char because int might match the return type of a gcc2
  8439. builtin and then its argument prototype would still apply. */
  8440. char glBegin();
  8441. int main() {
  8442. glBegin()
  8443. ; return 0; }
  8444. EOF
  8445. if { (eval echo configure:10380: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8446. rm -rf conftest*
  8447. eval "ac_cv_lib_$ac_lib_var=yes"
  8448. else
  8449. echo "configure: failed program was:" >&5
  8450. cat conftest.$ac_ext >&5
  8451. rm -rf conftest*
  8452. eval "ac_cv_lib_$ac_lib_var=no"
  8453. fi
  8454. rm -f conftest*
  8455. LIBS="$ac_save_LIBS"
  8456. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8457. echo "$ac_t""yes" 1>&6
  8458. OPENGLLIB="$OPENGLLIB -lGL "
  8459. else
  8460. echo "$ac_t""no" 1>&6
  8461. echo $ac_n "checking for glBegin in -lGL""... $ac_c" 1>&6
  8462. echo "configure:10399: checking for glBegin in -lGL" >&5
  8463. ac_lib_var=`echo GL'_'glBegin | sed 'y%./+-%__p_%'`
  8464. ac_save_LIBS="$LIBS"
  8465. LIBS="-lGL $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $MATHLIB -lXext $LIBS"
  8466. cat > conftest.$ac_ext <<EOF
  8467. #line 10405 "configure"
  8468. #include "confdefs.h"
  8469. /* Override any gcc2 internal prototype to avoid an error. */
  8470. /* We use char because int might match the return type of a gcc2
  8471. builtin and then its argument prototype would still apply. */
  8472. char glBegin();
  8473. int main() {
  8474. glBegin()
  8475. ; return 0; }
  8476. EOF
  8477. if { (eval echo configure:10416: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8478. rm -rf conftest*
  8479. eval "ac_cv_lib_$ac_lib_var=yes"
  8480. else
  8481. echo "configure: failed program was:" >&5
  8482. cat conftest.$ac_ext >&5
  8483. rm -rf conftest*
  8484. eval "ac_cv_lib_$ac_lib_var=no"
  8485. fi
  8486. rm -f conftest*
  8487. LIBS="$ac_save_LIBS"
  8488. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8489. echo "$ac_t""yes" 1>&6
  8490. OPENGLLIB="$OPENGLLIB -lGL -lXext"
  8491. else
  8492. echo "$ac_t""no" 1>&6
  8493. echo $ac_n "checking for glBegin in -lGL""... $ac_c" 1>&6
  8494. echo "configure:10435: checking for glBegin in -lGL" >&5
  8495. ac_lib_var=`echo GL'_'glBegin | sed 'y%./+-%__p_%'`
  8496. ac_save_LIBS="$LIBS"
  8497. LIBS="-lGL $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $MATHLIB -lpthread $LIBS"
  8498. cat > conftest.$ac_ext <<EOF
  8499. #line 10441 "configure"
  8500. #include "confdefs.h"
  8501. /* Override any gcc2 internal prototype to avoid an error. */
  8502. /* We use char because int might match the return type of a gcc2
  8503. builtin and then its argument prototype would still apply. */
  8504. char glBegin();
  8505. int main() {
  8506. glBegin()
  8507. ; return 0; }
  8508. EOF
  8509. if { (eval echo configure:10452: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8510. rm -rf conftest*
  8511. eval "ac_cv_lib_$ac_lib_var=yes"
  8512. else
  8513. echo "configure: failed program was:" >&5
  8514. cat conftest.$ac_ext >&5
  8515. rm -rf conftest*
  8516. eval "ac_cv_lib_$ac_lib_var=no"
  8517. fi
  8518. rm -f conftest*
  8519. LIBS="$ac_save_LIBS"
  8520. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8521. echo "$ac_t""yes" 1>&6
  8522. OPENGLLIB="$OPENGLLIB -lGL -lpthread"
  8523. else
  8524. echo "$ac_t""no" 1>&6
  8525. echo $ac_n "checking for glBegin in -lGL""... $ac_c" 1>&6
  8526. echo "configure:10471: checking for glBegin in -lGL" >&5
  8527. ac_lib_var=`echo GL'_'glBegin | sed 'y%./+-%__p_%'`
  8528. ac_save_LIBS="$LIBS"
  8529. LIBS="-lGL $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $MATHLIB -lpthread -lXext $LIBS"
  8530. cat > conftest.$ac_ext <<EOF
  8531. #line 10477 "configure"
  8532. #include "confdefs.h"
  8533. /* Override any gcc2 internal prototype to avoid an error. */
  8534. /* We use char because int might match the return type of a gcc2
  8535. builtin and then its argument prototype would still apply. */
  8536. char glBegin();
  8537. int main() {
  8538. glBegin()
  8539. ; return 0; }
  8540. EOF
  8541. if { (eval echo configure:10488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8542. rm -rf conftest*
  8543. eval "ac_cv_lib_$ac_lib_var=yes"
  8544. else
  8545. echo "configure: failed program was:" >&5
  8546. cat conftest.$ac_ext >&5
  8547. rm -rf conftest*
  8548. eval "ac_cv_lib_$ac_lib_var=no"
  8549. fi
  8550. rm -f conftest*
  8551. LIBS="$ac_save_LIBS"
  8552. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8553. echo "$ac_t""yes" 1>&6
  8554. OPENGLLIB="$OPENGLLIB -lGL -lpthread -lXext"
  8555. else
  8556. echo "$ac_t""no" 1>&6
  8557. LDFLAGS=${ac_save_ldflags}
  8558. { echo "configure: error: *** Unable to locate OpenGL library." 1>&2; exit 1; }
  8559. fi
  8560. fi
  8561. fi
  8562. fi
  8563. LDFLAGS=${ac_save_ldflags}
  8564. ac_save_ldflags="$LDFLAGS"
  8565. LDFLAGS="$OPENGL_LIB_PATH $LDFLAGS"
  8566. echo $ac_n "checking for gluBeginCurve in -lGLU""... $ac_c" 1>&6
  8567. echo "configure:10550: checking for gluBeginCurve in -lGLU" >&5
  8568. ac_lib_var=`echo GLU'_'gluBeginCurve | sed 'y%./+-%__p_%'`
  8569. ac_save_LIBS="$LIBS"
  8570. LIBS="-lGLU $OPENGLLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $MATHLIB $LIBS"
  8571. cat > conftest.$ac_ext <<EOF
  8572. #line 10556 "configure"
  8573. #include "confdefs.h"
  8574. /* Override any gcc2 internal prototype to avoid an error. */
  8575. /* We use char because int might match the return type of a gcc2
  8576. builtin and then its argument prototype would still apply. */
  8577. char gluBeginCurve();
  8578. int main() {
  8579. gluBeginCurve()
  8580. ; return 0; }
  8581. EOF
  8582. if { (eval echo configure:10567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8583. rm -rf conftest*
  8584. eval "ac_cv_lib_$ac_lib_var=yes"
  8585. else
  8586. echo "configure: failed program was:" >&5
  8587. cat conftest.$ac_ext >&5
  8588. rm -rf conftest*
  8589. eval "ac_cv_lib_$ac_lib_var=no"
  8590. fi
  8591. rm -f conftest*
  8592. LIBS="$ac_save_LIBS"
  8593. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8594. echo "$ac_t""yes" 1>&6
  8595. OPENGLULIB="$OPENGLULIB -lGLU "
  8596. else
  8597. echo "$ac_t""no" 1>&6
  8598. echo $ac_n "checking for gluBeginCurve in -lGLU""... $ac_c" 1>&6
  8599. echo "configure:10586: checking for gluBeginCurve in -lGLU" >&5
  8600. ac_lib_var=`echo GLU'_'gluBeginCurve | sed 'y%./+-%__p_%'`
  8601. ac_save_LIBS="$LIBS"
  8602. LIBS="-lGLU $OPENGLLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $MATHLIB -lstdc++ $LIBS"
  8603. cat > conftest.$ac_ext <<EOF
  8604. #line 10592 "configure"
  8605. #include "confdefs.h"
  8606. /* Override any gcc2 internal prototype to avoid an error. */
  8607. /* We use char because int might match the return type of a gcc2
  8608. builtin and then its argument prototype would still apply. */
  8609. char gluBeginCurve();
  8610. int main() {
  8611. gluBeginCurve()
  8612. ; return 0; }
  8613. EOF
  8614. if { (eval echo configure:10603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8615. rm -rf conftest*
  8616. eval "ac_cv_lib_$ac_lib_var=yes"
  8617. else
  8618. echo "configure: failed program was:" >&5
  8619. cat conftest.$ac_ext >&5
  8620. rm -rf conftest*
  8621. eval "ac_cv_lib_$ac_lib_var=no"
  8622. fi
  8623. rm -f conftest*
  8624. LIBS="$ac_save_LIBS"
  8625. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  8626. echo "$ac_t""yes" 1>&6
  8627. OPENGLULIB="$OPENGLULIB -lGLU -lstdc++"
  8628. else
  8629. echo "$ac_t""no" 1>&6
  8630. LDFLAGS=${ac_save_ldflags}
  8631. { echo "configure: error: *** Unable to locate GLU library." 1>&2; exit 1; }
  8632. fi
  8633. fi
  8634. LDFLAGS=${ac_save_ldflags}
  8635. OPENGLLIB="$OPENGL_LIB_PATH $OPENGLLIB"
  8636. OPENGLULIB="$OPENGL_LIB_PATH $OPENGLULIB"
  8637. ac_save_libs="$LIBS"
  8638. ac_save_ldflags="$LDFLAGS"
  8639. LIBS=" $OPENGLLIB $LIBS"
  8640. LDFLAGS=" $LDFLAGS"
  8641. echo $ac_n "checking for glXCreatePbuffer""... $ac_c" 1>&6
  8642. echo "configure:10650: checking for glXCreatePbuffer" >&5
  8643. cat > conftest.$ac_ext <<EOF
  8644. #line 10653 "configure"
  8645. #include "confdefs.h"
  8646. /* System header to define __stub macros and hopefully few prototypes,
  8647. which can conflict with char glXCreatePbuffer(); below. */
  8648. #include <assert.h>
  8649. /* Override any gcc2 internal prototype to avoid an error. */
  8650. /* We use char because int might match the return type of a gcc2
  8651. builtin and then its argument prototype would still apply. */
  8652. char glXCreatePbuffer();
  8653. int main() {
  8654. /* The GNU C library defines this for functions which it implements
  8655. to always fail with ENOSYS. Some functions are actually named
  8656. something starting with __ and the normal name is an alias. */
  8657. #if defined (__stub_glXCreatePbuffer) || defined (__stub___glXCreatePbuffer)
  8658. choke me
  8659. #else
  8660. glXCreatePbuffer();
  8661. #endif
  8662. ; return 0; }
  8663. EOF
  8664. if { (eval echo configure:10676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8665. rm -rf conftest*
  8666. eval "ac_cv_func_glXCreatePbuffer=yes"
  8667. else
  8668. echo "configure: failed program was:" >&5
  8669. cat conftest.$ac_ext >&5
  8670. rm -rf conftest*
  8671. eval "ac_cv_func_glXCreatePbuffer=no"
  8672. fi
  8673. rm -f conftest*
  8674. if eval "test \"`echo '$ac_cv_func_'glXCreatePbuffer`\" = yes"; then
  8675. echo "$ac_t""yes" 1>&6
  8676. cat >> confdefs.h <<\EOF
  8677. #define HAVE_PBUFFERS 1
  8678. EOF
  8679. else
  8680. echo "$ac_t""no" 1>&6
  8681. { echo "configure: error: *** Unable to locate ." 1>&2; exit 1; }
  8682. fi
  8683. LIBS=${ac_save_libs}
  8684. LDFLAGS=${ac_save_ldflags}
  8685. ac_save_libs="$LIBS"
  8686. ac_save_ldflags="$LDFLAGS"
  8687. LIBS=" $OPENGLLIB $LIBS"
  8688. LDFLAGS=" $LDFLAGS"
  8689. echo $ac_n "checking for glXCreateGLXPixmap""... $ac_c" 1>&6
  8690. echo "configure:10713: checking for glXCreateGLXPixmap" >&5
  8691. cat > conftest.$ac_ext <<EOF
  8692. #line 10716 "configure"
  8693. #include "confdefs.h"
  8694. /* System header to define __stub macros and hopefully few prototypes,
  8695. which can conflict with char glXCreateGLXPixmap(); below. */
  8696. #include <assert.h>
  8697. /* Override any gcc2 internal prototype to avoid an error. */
  8698. /* We use char because int might match the return type of a gcc2
  8699. builtin and then its argument prototype would still apply. */
  8700. char glXCreateGLXPixmap();
  8701. int main() {
  8702. /* The GNU C library defines this for functions which it implements
  8703. to always fail with ENOSYS. Some functions are actually named
  8704. something starting with __ and the normal name is an alias. */
  8705. #if defined (__stub_glXCreateGLXPixmap) || defined (__stub___glXCreateGLXPixmap)
  8706. choke me
  8707. #else
  8708. glXCreateGLXPixmap();
  8709. #endif
  8710. ; return 0; }
  8711. EOF
  8712. if { (eval echo configure:10739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8713. rm -rf conftest*
  8714. eval "ac_cv_func_glXCreateGLXPixmap=yes"
  8715. else
  8716. echo "configure: failed program was:" >&5
  8717. cat conftest.$ac_ext >&5
  8718. rm -rf conftest*
  8719. eval "ac_cv_func_glXCreateGLXPixmap=no"
  8720. fi
  8721. rm -f conftest*
  8722. if eval "test \"`echo '$ac_cv_func_'glXCreateGLXPixmap`\" = yes"; then
  8723. echo "$ac_t""yes" 1>&6
  8724. cat >> confdefs.h <<\EOF
  8725. #define HAVE_PIXMAPS 1
  8726. EOF
  8727. else
  8728. echo "$ac_t""no" 1>&6
  8729. { echo "configure: error: *** Unable to locate ." 1>&2; exit 1; }
  8730. fi
  8731. LIBS=${ac_save_libs}
  8732. LDFLAGS=${ac_save_ldflags}
  8733. cat >> confdefs.h <<\EOF
  8734. #define OPENGL_X11 1
  8735. EOF
  8736. fi # $OPENGL_X11
  8737. if test "$OPENGL_AQUA" = 1 ; then
  8738. echo $ac_n "checking for location of OpenGL framework""... $ac_c" 1>&6
  8739. echo "configure:10782: checking for location of OpenGL framework" >&5
  8740. case "$with_opengl_framework" in
  8741. y | ye | yes | n | no)
  8742. { echo "configure: error: *** You must supply a directory to --with-opengl-framework." 1>&2; exit 1; }
  8743. ;;
  8744. esac
  8745. echo "$ac_t""$with_opengl_framework" 1>&6
  8746. if test -n "$with_opengl_framework"; then
  8747. if test -d $with_opengl_framework; then
  8748. OPENGLPATH="$OPENGLPATH -F$with_opengl_framework"
  8749. else
  8750. { echo "configure: error: *** OpenGL framework directory $dir does not exist." 1>&2; exit 1; }
  8751. fi
  8752. fi
  8753. ac_save_cppflags="$CPPFLAGS"
  8754. CPPFLAGS="$OPENGLPATH $CPPFLAGS"
  8755. for ac_hdr in OpenGL/gl.h OpenGL/glu.h
  8756. do
  8757. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  8758. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  8759. echo "configure:10806: checking for $ac_hdr" >&5
  8760. cat > conftest.$ac_ext <<EOF
  8761. #line 10809 "configure"
  8762. #include "confdefs.h"
  8763. #include <$ac_hdr>
  8764. EOF
  8765. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  8766. { (eval echo configure:10814: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  8767. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  8768. if test -z "$ac_err"; then
  8769. rm -rf conftest*
  8770. eval "ac_cv_header_$ac_safe=yes"
  8771. else
  8772. echo "$ac_err" >&5
  8773. echo "configure: failed program was:" >&5
  8774. cat conftest.$ac_ext >&5
  8775. rm -rf conftest*
  8776. eval "ac_cv_header_$ac_safe=no"
  8777. fi
  8778. rm -f conftest*
  8779. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  8780. echo "$ac_t""yes" 1>&6
  8781. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  8782. cat >> confdefs.h <<EOF
  8783. #define $ac_tr_hdr 1
  8784. EOF
  8785. else
  8786. echo "$ac_t""no" 1>&6
  8787. { echo "configure: error: *** Unable to locate OpenGL includes." 1>&2; exit 1; }
  8788. fi
  8789. done
  8790. CPPFLAGS=$ac_save_cppflags
  8791. ac_save_libs="$LIBS"
  8792. ac_save_ldflags="$LDFLAGS"
  8793. LIBS="-framework OpenGL -framework AGL -framework ApplicationServices $LIBS"
  8794. LDFLAGS="$OPENGLPATH $LDFLAGS"
  8795. echo $ac_n "checking for glBegin""... $ac_c" 1>&6
  8796. echo "configure:10850: checking for glBegin" >&5
  8797. cat > conftest.$ac_ext <<EOF
  8798. #line 10853 "configure"
  8799. #include "confdefs.h"
  8800. /* System header to define __stub macros and hopefully few prototypes,
  8801. which can conflict with char glBegin(); below. */
  8802. #include <assert.h>
  8803. /* Override any gcc2 internal prototype to avoid an error. */
  8804. /* We use char because int might match the return type of a gcc2
  8805. builtin and then its argument prototype would still apply. */
  8806. char glBegin();
  8807. int main() {
  8808. /* The GNU C library defines this for functions which it implements
  8809. to always fail with ENOSYS. Some functions are actually named
  8810. something starting with __ and the normal name is an alias. */
  8811. #if defined (__stub_glBegin) || defined (__stub___glBegin)
  8812. choke me
  8813. #else
  8814. glBegin();
  8815. #endif
  8816. ; return 0; }
  8817. EOF
  8818. if { (eval echo configure:10876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8819. rm -rf conftest*
  8820. eval "ac_cv_func_glBegin=yes"
  8821. else
  8822. echo "configure: failed program was:" >&5
  8823. cat conftest.$ac_ext >&5
  8824. rm -rf conftest*
  8825. eval "ac_cv_func_glBegin=no"
  8826. fi
  8827. rm -f conftest*
  8828. if eval "test \"`echo '$ac_cv_func_'glBegin`\" = yes"; then
  8829. echo "$ac_t""yes" 1>&6
  8830. OPENGLLIB="$OPENGLLIB -framework OpenGL -framework AGL -framework ApplicationServices"
  8831. else
  8832. echo "$ac_t""no" 1>&6
  8833. { echo "configure: error: *** Unable to locate glBegin." 1>&2; exit 1; }
  8834. fi
  8835. LIBS=${ac_save_libs}
  8836. LDFLAGS=${ac_save_ldflags}
  8837. ac_save_libs="$LIBS"
  8838. ac_save_ldflags="$LDFLAGS"
  8839. LIBS=" $OPENGLLIB $LIBS"
  8840. LDFLAGS="$OPENGLPATH $LDFLAGS"
  8841. echo $ac_n "checking for gluBeginCurve""... $ac_c" 1>&6
  8842. echo "configure:10913: checking for gluBeginCurve" >&5
  8843. cat > conftest.$ac_ext <<EOF
  8844. #line 10916 "configure"
  8845. #include "confdefs.h"
  8846. /* System header to define __stub macros and hopefully few prototypes,
  8847. which can conflict with char gluBeginCurve(); below. */
  8848. #include <assert.h>
  8849. /* Override any gcc2 internal prototype to avoid an error. */
  8850. /* We use char because int might match the return type of a gcc2
  8851. builtin and then its argument prototype would still apply. */
  8852. char gluBeginCurve();
  8853. int main() {
  8854. /* The GNU C library defines this for functions which it implements
  8855. to always fail with ENOSYS. Some functions are actually named
  8856. something starting with __ and the normal name is an alias. */
  8857. #if defined (__stub_gluBeginCurve) || defined (__stub___gluBeginCurve)
  8858. choke me
  8859. #else
  8860. gluBeginCurve();
  8861. #endif
  8862. ; return 0; }
  8863. EOF
  8864. if { (eval echo configure:10939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8865. rm -rf conftest*
  8866. eval "ac_cv_func_gluBeginCurve=yes"
  8867. else
  8868. echo "configure: failed program was:" >&5
  8869. cat conftest.$ac_ext >&5
  8870. rm -rf conftest*
  8871. eval "ac_cv_func_gluBeginCurve=no"
  8872. fi
  8873. rm -f conftest*
  8874. if eval "test \"`echo '$ac_cv_func_'gluBeginCurve`\" = yes"; then
  8875. echo "$ac_t""yes" 1>&6
  8876. OPENGLLIB="$OPENGLLIB "
  8877. else
  8878. echo "$ac_t""no" 1>&6
  8879. { echo "configure: error: *** Unable to locate gluBeginCurve." 1>&2; exit 1; }
  8880. fi
  8881. LIBS=${ac_save_libs}
  8882. LDFLAGS=${ac_save_ldflags}
  8883. OPENGLINC="$OPENGLPATH"
  8884. OPENGLLIBPATH="$OPENGLPATH"
  8885. cat >> confdefs.h <<\EOF
  8886. #define OPENGL_AQUA 1
  8887. EOF
  8888. fi # $OPENGL_AQUA
  8889. if test "$OPENGL_WINDOWS" = 1 ; then
  8890. # With OpenGL includes directory
  8891. echo $ac_n "checking for location of OpenGL includes""... $ac_c" 1>&6
  8892. echo "configure:10987: checking for location of OpenGL includes" >&5
  8893. case "$with_opengl_includes" in
  8894. y | ye | yes | n | no)
  8895. { echo "configure: error: *** You must supply a directory to --with-opengl-includes." 1>&2; exit 1; }
  8896. ;;
  8897. esac
  8898. echo "$ac_t""$with_opengl_includes" 1>&6
  8899. if test -n "$with_opengl_includes" ; then
  8900. for dir in $with_opengl_includes; do
  8901. if test -d "$dir"; then
  8902. OPENGLINC="$OPENGLINC -I$dir"
  8903. else
  8904. { echo "configure: error: *** OpenGL includes directory $dir does not exist." 1>&2; exit 1; }
  8905. fi
  8906. done
  8907. fi
  8908. ac_save_cppflags="$CPPFLAGS"
  8909. CPPFLAGS="$OPENGLINC $CPPFLAGS"
  8910. for ac_hdr in GL/gl.h GL/glu.h
  8911. do
  8912. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  8913. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  8914. echo "configure:11013: checking for $ac_hdr" >&5
  8915. cat > conftest.$ac_ext <<EOF
  8916. #line 11016 "configure"
  8917. #include "confdefs.h"
  8918. #include <$ac_hdr>
  8919. EOF
  8920. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  8921. { (eval echo configure:11021: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  8922. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  8923. if test -z "$ac_err"; then
  8924. rm -rf conftest*
  8925. eval "ac_cv_header_$ac_safe=yes"
  8926. else
  8927. echo "$ac_err" >&5
  8928. echo "configure: failed program was:" >&5
  8929. cat conftest.$ac_ext >&5
  8930. rm -rf conftest*
  8931. eval "ac_cv_header_$ac_safe=no"
  8932. fi
  8933. rm -f conftest*
  8934. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  8935. echo "$ac_t""yes" 1>&6
  8936. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  8937. cat >> confdefs.h <<EOF
  8938. #define $ac_tr_hdr 1
  8939. EOF
  8940. else
  8941. echo "$ac_t""no" 1>&6
  8942. { echo "configure: error: *** Unable to locate OpenGL includes." 1>&2; exit 1; }
  8943. fi
  8944. done
  8945. CPPFLAGS=$ac_save_cppflags
  8946. # With OpenGL library directory
  8947. echo $ac_n "checking for location of OpenGL library""... $ac_c" 1>&6
  8948. echo "configure:11055: checking for location of OpenGL library" >&5
  8949. case "$with_opengl_libs" in
  8950. y | ye | yes | n | no)
  8951. { echo "configure: error: *** You must supply a directory to --with-opengl-libs." 1>&2; exit 1; }
  8952. ;;
  8953. esac
  8954. echo "$ac_t""$with_opengl_libs" 1>&6
  8955. if test -n "$with_opengl_libs"; then
  8956. for dir in $with_opengl_libs; do
  8957. if test -d "$dir"; then
  8958. OPENGL_LIB_PATH="$OPENGL_LIB_PATH -L$dir"
  8959. else
  8960. { echo "configure: error: *** OpenGL library directory $dir does not exist." 1>&2; exit 1; }
  8961. fi
  8962. done
  8963. fi
  8964. ac_save_cflags="$CFLAGS"
  8965. CFLAGS="$CFLAGS $OPENGLINC"
  8966. ac_save_ldflags="$LDFLAGS"
  8967. ac_save_libs="$LIBS"
  8968. echo $ac_n "checking for OpenGL library""... $ac_c" 1>&6
  8969. echo "configure:11080: checking for OpenGL library" >&5
  8970. LDFLAGS="$OPENGL_LIB_PATH $LDFLAGS"
  8971. LIBS="-lopengl32 "
  8972. cat > conftest.$ac_ext <<EOF
  8973. #line 11084 "configure"
  8974. #include "confdefs.h"
  8975. #include <GL/gl.h>
  8976. int main() {
  8977. glEnd();
  8978. ; return 0; }
  8979. EOF
  8980. if { (eval echo configure:11091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  8981. rm -rf conftest*
  8982. echo "$ac_t""found" 1>&6
  8983. OPENGLLIB="$OPENGLLIB -lopengl32 "
  8984. else
  8985. echo "configure: failed program was:" >&5
  8986. cat conftest.$ac_ext >&5
  8987. rm -rf conftest*
  8988. { echo "configure: error: *** Unable to locate OpenGL library." 1>&2; exit 1; }
  8989. fi
  8990. rm -f conftest*
  8991. LIBS=${ac_save_libs}
  8992. LDFLAGS=${ac_save_ldflags}
  8993. ac_save_ldflags="$LDFLAGS"
  8994. ac_save_libs="$LIBS"
  8995. echo $ac_n "checking for GLU library""... $ac_c" 1>&6
  8996. echo "configure:11115: checking for GLU library" >&5
  8997. LDFLAGS="$OPENGL_LIB_PATH $LDFLAGS"
  8998. LIBS="-lglu32 $OPENGLLIB "
  8999. cat > conftest.$ac_ext <<EOF
  9000. #line 11119 "configure"
  9001. #include "confdefs.h"
  9002. #include <GL/glu.h>
  9003. int main() {
  9004. gluNewQuadric();
  9005. ; return 0; }
  9006. EOF
  9007. if { (eval echo configure:11126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9008. rm -rf conftest*
  9009. echo "$ac_t""found" 1>&6
  9010. OPENGLULIB="$OPENGLULIB -lglu32 "
  9011. else
  9012. echo "configure: failed program was:" >&5
  9013. cat conftest.$ac_ext >&5
  9014. rm -rf conftest*
  9015. { echo "configure: error: *** Unable to locate GLU library." 1>&2; exit 1; }
  9016. fi
  9017. rm -f conftest*
  9018. LIBS=${ac_save_libs}
  9019. LDFLAGS=${ac_save_ldflags}
  9020. CFLAGS=${ac_save_cflags}
  9021. OPENGLLIB="$OPENGL_LIB_PATH $OPENGLLIB"
  9022. OPENGLULIB="$OPENGL_LIB_PATH $OPENGLULIB"
  9023. cat >> confdefs.h <<\EOF
  9024. #define OPENGL_WINDOWS 1
  9025. EOF
  9026. fi # $OPENGL_WINDOWS
  9027. fi # $USE_OPENGL
  9028. # Done checking OpenGL
  9029. # Enable TCLTK option
  9030. echo $ac_n "checking whether to use Tcl/Tk""... $ac_c" 1>&6
  9031. echo "configure:11175: checking whether to use Tcl/Tk" >&5
  9032. echo "$ac_t"""$with_tcltk"" 1>&6
  9033. case "$with_tcltk" in
  9034. "no") USE_TCLTK= ;;
  9035. "yes") USE_TCLTK="1" ;;
  9036. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  9037. esac
  9038. TCLINCDIR=
  9039. TCLTKLIBPATH=
  9040. TCLTKLIBS=
  9041. if test -n "$USE_TCLTK"; then
  9042. # With Tcl/Tk includes directory
  9043. echo $ac_n "checking for location of Tcl/Tk includes""... $ac_c" 1>&6
  9044. echo "configure:11195: checking for location of Tcl/Tk includes" >&5
  9045. case "$with_tcltk_includes" in
  9046. y | ye | yes | n | no)
  9047. { echo "configure: error: *** You must supply a directory to --with-tcltk-includes." 1>&2; exit 1; }
  9048. ;;
  9049. esac
  9050. echo "$ac_t""$with_tcltk_includes" 1>&6
  9051. if test -n "$with_tcltk_includes" ; then
  9052. for dir in $with_tcltk_includes; do
  9053. if test -d "$dir"; then
  9054. TCLINCDIR="$TCLINCDIR -I$dir"
  9055. else
  9056. { echo "configure: error: *** Tcl/Tk includes directory $dir does not exist." 1>&2; exit 1; }
  9057. fi
  9058. done
  9059. fi
  9060. ac_save_cppflags="$CPPFLAGS"
  9061. CPPFLAGS="$TCLINCDIR $CPPFLAGS"
  9062. for ac_hdr in tcl.h
  9063. do
  9064. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  9065. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  9066. echo "configure:11221: checking for $ac_hdr" >&5
  9067. cat > conftest.$ac_ext <<EOF
  9068. #line 11224 "configure"
  9069. #include "confdefs.h"
  9070. #include <$ac_hdr>
  9071. EOF
  9072. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  9073. { (eval echo configure:11229: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  9074. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  9075. if test -z "$ac_err"; then
  9076. rm -rf conftest*
  9077. eval "ac_cv_header_$ac_safe=yes"
  9078. else
  9079. echo "$ac_err" >&5
  9080. echo "configure: failed program was:" >&5
  9081. cat conftest.$ac_ext >&5
  9082. rm -rf conftest*
  9083. eval "ac_cv_header_$ac_safe=no"
  9084. fi
  9085. rm -f conftest*
  9086. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  9087. echo "$ac_t""yes" 1>&6
  9088. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  9089. cat >> confdefs.h <<EOF
  9090. #define $ac_tr_hdr 1
  9091. EOF
  9092. else
  9093. echo "$ac_t""no" 1>&6
  9094. { echo "configure: error: *** Unable to locate Tcl includes." 1>&2; exit 1; }
  9095. fi
  9096. done
  9097. CPPFLAGS=$ac_save_cppflags
  9098. ac_save_cppflags="$CPPFLAGS"
  9099. CPPFLAGS="$TCLINCDIR $X_CFLAGS $CPPFLAGS"
  9100. for ac_hdr in tk.h
  9101. do
  9102. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  9103. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  9104. echo "configure:11266: checking for $ac_hdr" >&5
  9105. cat > conftest.$ac_ext <<EOF
  9106. #line 11269 "configure"
  9107. #include "confdefs.h"
  9108. #include <$ac_hdr>
  9109. EOF
  9110. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  9111. { (eval echo configure:11274: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  9112. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  9113. if test -z "$ac_err"; then
  9114. rm -rf conftest*
  9115. eval "ac_cv_header_$ac_safe=yes"
  9116. else
  9117. echo "$ac_err" >&5
  9118. echo "configure: failed program was:" >&5
  9119. cat conftest.$ac_ext >&5
  9120. rm -rf conftest*
  9121. eval "ac_cv_header_$ac_safe=no"
  9122. fi
  9123. rm -f conftest*
  9124. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  9125. echo "$ac_t""yes" 1>&6
  9126. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  9127. cat >> confdefs.h <<EOF
  9128. #define $ac_tr_hdr 1
  9129. EOF
  9130. else
  9131. echo "$ac_t""no" 1>&6
  9132. { echo "configure: error: *** Unable to locate Tk includes." 1>&2; exit 1; }
  9133. fi
  9134. done
  9135. CPPFLAGS=$ac_save_cppflags
  9136. # Tcl/Tk version checks
  9137. echo $ac_n "checking Tcl version""... $ac_c" 1>&6
  9138. echo "configure:11308: checking Tcl version" >&5
  9139. ac_save_cppflags="$CPPFLAGS"
  9140. CPPFLAGS="$TCLINCDIR $CPPFLAGS"
  9141. if test "$cross_compiling" = yes; then
  9142. tcl_ver=UNKNOWN
  9143. echo "$ac_t""unknown (cross-compiling)" 1>&6
  9144. else
  9145. cat > conftest.$ac_ext <<EOF
  9146. #line 11316 "configure"
  9147. #include "confdefs.h"
  9148. #include <stdio.h>
  9149. #include <tcl.h>
  9150. int main(void) {
  9151. FILE *fp = fopen("conftestdata","w");
  9152. fputs(TCL_VERSION, fp);
  9153. return 0;
  9154. }
  9155. EOF
  9156. if { (eval echo configure:11328: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  9157. then
  9158. tcl_ver=`cat conftestdata`
  9159. echo "$ac_t""$tcl_ver" 1>&6
  9160. else
  9161. echo "configure: failed program was:" >&5
  9162. cat conftest.$ac_ext >&5
  9163. rm -fr conftest*
  9164. { echo "configure: error: *** Could not determine Tcl version." 1>&2; exit 1; }
  9165. fi
  9166. rm -fr conftest*
  9167. fi
  9168. CPPFLAGS=$ac_save_cppflags
  9169. echo $ac_n "checking Tk version""... $ac_c" 1>&6
  9170. echo "configure:11346: checking Tk version" >&5
  9171. ac_save_cppflags="$CPPFLAGS"
  9172. CPPFLAGS="$TCLINCDIR $X_CFLAGS $CPPFLAGS"
  9173. if test "$cross_compiling" = yes; then
  9174. tk_ver=UNKNOWN
  9175. echo "$ac_t""unknown (cross-compiling)" 1>&6
  9176. else
  9177. cat > conftest.$ac_ext <<EOF
  9178. #line 11354 "configure"
  9179. #include "confdefs.h"
  9180. #include <stdio.h>
  9181. #include <tk.h>
  9182. int main(void) {
  9183. FILE *fp = fopen("conftestdata","w");
  9184. fputs(TK_VERSION, fp);
  9185. return 0;
  9186. }
  9187. EOF
  9188. if { (eval echo configure:11366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
  9189. then
  9190. tk_ver=`cat conftestdata`
  9191. echo "$ac_t""$tk_ver" 1>&6
  9192. else
  9193. echo "configure: failed program was:" >&5
  9194. cat conftest.$ac_ext >&5
  9195. rm -fr conftest*
  9196. { echo "configure: error: *** Could not determine Tk version." 1>&2; exit 1; }
  9197. fi
  9198. rm -fr conftest*
  9199. fi
  9200. CPPFLAGS=$ac_save_cppflags
  9201. if test "$tcl_ver" = "$tk_ver" ; then
  9202. tcltk_ver=$tcl_ver
  9203. else
  9204. { echo "configure: error: *** Tcl/Tk version mismatch." 1>&2; exit 1; }
  9205. fi
  9206. # FreeBSD and CygWin don't have a "dot" between major/minor version number
  9207. tcltk_ver2=`echo $tcltk_ver | sed 's/\.//g'`
  9208. # With Tcl/Tk library directory
  9209. echo $ac_n "checking for location of Tcl/Tk library""... $ac_c" 1>&6
  9210. echo "configure:11395: checking for location of Tcl/Tk library" >&5
  9211. case "$with_tcltk_libs" in
  9212. y | ye | yes | n | no)
  9213. { echo "configure: error: *** You must supply a directory to --with-tcltk-libs." 1>&2; exit 1; }
  9214. ;;
  9215. esac
  9216. echo "$ac_t""$with_tcltk_libs" 1>&6
  9217. if test -n "$with_tcltk_libs"; then
  9218. for dir in $with_tcltk_libs; do
  9219. if test -d "$dir"; then
  9220. TCLTKLIBPATH="$TCLTKLIBPATH -L$dir"
  9221. else
  9222. { echo "configure: error: *** Tcl/Tk library directory $dir does not exist." 1>&2; exit 1; }
  9223. fi
  9224. done
  9225. fi
  9226. TCLLIB=
  9227. TKLIB=
  9228. # Can't test tcl/tk libs on 64bit OSX Aqua for now
  9229. # assume that if OpenGL Aqua, then user specifies TclTk Aqua,
  9230. # as there is no test for Tcl/Tk Aqua and Tck/Tk X11 won't work
  9231. TCLTKAQUA_IS64BIT=
  9232. if test "$OPENGL_AQUA" = 1 ; then
  9233. temp_CFLAGS="$CFLAGS"
  9234. CFLAGS="`echo \"$CFLAGS\" | sed -E 's/-arch +x86_64//g' | sed -E 's/-arch +ppc64//g'`"
  9235. # can't save LDFLAGS, need to remember arch flags to insert back later
  9236. temp_ARCHES=
  9237. for a in x86_64 ppc64
  9238. do
  9239. if test -n "`echo \"$LDFLAGS\" | grep -E -e '-arch +'$a`" ; then
  9240. temp_ARCHES="$temp_ARCHES -arch $a"
  9241. fi
  9242. done
  9243. LDFLAGS="`echo \"$LDFLAGS\" | sed -E 's/-arch +x86_64//g' | sed -E 's/-arch +ppc64//g'`"
  9244. fi
  9245. ac_save_ldflags="$LDFLAGS"
  9246. LDFLAGS="$TCLTKLIBPATH $LDFLAGS"
  9247. echo $ac_n "checking for Tcl_Init in -ltcl""... $ac_c" 1>&6
  9248. echo "configure:11443: checking for Tcl_Init in -ltcl" >&5
  9249. ac_lib_var=`echo tcl'_'Tcl_Init | sed 'y%./+-%__p_%'`
  9250. ac_save_LIBS="$LIBS"
  9251. LIBS="-ltcl $MATHLIB $LIBS"
  9252. cat > conftest.$ac_ext <<EOF
  9253. #line 11449 "configure"
  9254. #include "confdefs.h"
  9255. /* Override any gcc2 internal prototype to avoid an error. */
  9256. /* We use char because int might match the return type of a gcc2
  9257. builtin and then its argument prototype would still apply. */
  9258. char Tcl_Init();
  9259. int main() {
  9260. Tcl_Init()
  9261. ; return 0; }
  9262. EOF
  9263. if { (eval echo configure:11460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9264. rm -rf conftest*
  9265. eval "ac_cv_lib_$ac_lib_var=yes"
  9266. else
  9267. echo "configure: failed program was:" >&5
  9268. cat conftest.$ac_ext >&5
  9269. rm -rf conftest*
  9270. eval "ac_cv_lib_$ac_lib_var=no"
  9271. fi
  9272. rm -f conftest*
  9273. LIBS="$ac_save_LIBS"
  9274. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9275. echo "$ac_t""yes" 1>&6
  9276. TCLLIB="$TCLLIB -ltcl $MATHLIB"
  9277. else
  9278. echo "$ac_t""no" 1>&6
  9279. echo $ac_n "checking for Tcl_Init in -ltcl""... $ac_c" 1>&6
  9280. echo "configure:11479: checking for Tcl_Init in -ltcl" >&5
  9281. ac_lib_var=`echo tcl'_'Tcl_Init | sed 'y%./+-%__p_%'`
  9282. ac_save_LIBS="$LIBS"
  9283. LIBS="-ltcl $MATHLIB $DLLIB $LIBS"
  9284. cat > conftest.$ac_ext <<EOF
  9285. #line 11485 "configure"
  9286. #include "confdefs.h"
  9287. /* Override any gcc2 internal prototype to avoid an error. */
  9288. /* We use char because int might match the return type of a gcc2
  9289. builtin and then its argument prototype would still apply. */
  9290. char Tcl_Init();
  9291. int main() {
  9292. Tcl_Init()
  9293. ; return 0; }
  9294. EOF
  9295. if { (eval echo configure:11496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9296. rm -rf conftest*
  9297. eval "ac_cv_lib_$ac_lib_var=yes"
  9298. else
  9299. echo "configure: failed program was:" >&5
  9300. cat conftest.$ac_ext >&5
  9301. rm -rf conftest*
  9302. eval "ac_cv_lib_$ac_lib_var=no"
  9303. fi
  9304. rm -f conftest*
  9305. LIBS="$ac_save_LIBS"
  9306. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9307. echo "$ac_t""yes" 1>&6
  9308. TCLLIB="$TCLLIB -ltcl $MATHLIB $DLLIB"
  9309. else
  9310. echo "$ac_t""no" 1>&6
  9311. LDFLAGS=${ac_save_ldflags}
  9312. ac_save_ldflags="$LDFLAGS"
  9313. LDFLAGS="$TCLTKLIBPATH $LDFLAGS"
  9314. echo $ac_n "checking for Tcl_Init in -ltcl$tcltk_ver""... $ac_c" 1>&6
  9315. echo "configure:11523: checking for Tcl_Init in -ltcl$tcltk_ver" >&5
  9316. ac_lib_var=`echo tcl$tcltk_ver'_'Tcl_Init | sed 'y%./+-%__p_%'`
  9317. ac_save_LIBS="$LIBS"
  9318. LIBS="-ltcl$tcltk_ver $MATHLIB $LIBS"
  9319. cat > conftest.$ac_ext <<EOF
  9320. #line 11529 "configure"
  9321. #include "confdefs.h"
  9322. /* Override any gcc2 internal prototype to avoid an error. */
  9323. /* We use char because int might match the return type of a gcc2
  9324. builtin and then its argument prototype would still apply. */
  9325. char Tcl_Init();
  9326. int main() {
  9327. Tcl_Init()
  9328. ; return 0; }
  9329. EOF
  9330. if { (eval echo configure:11540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9331. rm -rf conftest*
  9332. eval "ac_cv_lib_$ac_lib_var=yes"
  9333. else
  9334. echo "configure: failed program was:" >&5
  9335. cat conftest.$ac_ext >&5
  9336. rm -rf conftest*
  9337. eval "ac_cv_lib_$ac_lib_var=no"
  9338. fi
  9339. rm -f conftest*
  9340. LIBS="$ac_save_LIBS"
  9341. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9342. echo "$ac_t""yes" 1>&6
  9343. TCLLIB="$TCLLIB -ltcl$tcltk_ver $MATHLIB"
  9344. else
  9345. echo "$ac_t""no" 1>&6
  9346. echo $ac_n "checking for Tcl_Init in -ltcl$tcltk_ver""... $ac_c" 1>&6
  9347. echo "configure:11559: checking for Tcl_Init in -ltcl$tcltk_ver" >&5
  9348. ac_lib_var=`echo tcl$tcltk_ver'_'Tcl_Init | sed 'y%./+-%__p_%'`
  9349. ac_save_LIBS="$LIBS"
  9350. LIBS="-ltcl$tcltk_ver $MATHLIB $DLLIB $LIBS"
  9351. cat > conftest.$ac_ext <<EOF
  9352. #line 11565 "configure"
  9353. #include "confdefs.h"
  9354. /* Override any gcc2 internal prototype to avoid an error. */
  9355. /* We use char because int might match the return type of a gcc2
  9356. builtin and then its argument prototype would still apply. */
  9357. char Tcl_Init();
  9358. int main() {
  9359. Tcl_Init()
  9360. ; return 0; }
  9361. EOF
  9362. if { (eval echo configure:11576: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9363. rm -rf conftest*
  9364. eval "ac_cv_lib_$ac_lib_var=yes"
  9365. else
  9366. echo "configure: failed program was:" >&5
  9367. cat conftest.$ac_ext >&5
  9368. rm -rf conftest*
  9369. eval "ac_cv_lib_$ac_lib_var=no"
  9370. fi
  9371. rm -f conftest*
  9372. LIBS="$ac_save_LIBS"
  9373. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9374. echo "$ac_t""yes" 1>&6
  9375. TCLLIB="$TCLLIB -ltcl$tcltk_ver $MATHLIB $DLLIB"
  9376. else
  9377. echo "$ac_t""no" 1>&6
  9378. LDFLAGS=${ac_save_ldflags}
  9379. ac_save_ldflags="$LDFLAGS"
  9380. LDFLAGS="$TCLTKLIBPATH $LDFLAGS"
  9381. echo $ac_n "checking for Tcl_Init in -ltcl$tcltk_ver2""... $ac_c" 1>&6
  9382. echo "configure:11603: checking for Tcl_Init in -ltcl$tcltk_ver2" >&5
  9383. ac_lib_var=`echo tcl$tcltk_ver2'_'Tcl_Init | sed 'y%./+-%__p_%'`
  9384. ac_save_LIBS="$LIBS"
  9385. LIBS="-ltcl$tcltk_ver2 $MATHLIB $LIBS"
  9386. cat > conftest.$ac_ext <<EOF
  9387. #line 11609 "configure"
  9388. #include "confdefs.h"
  9389. /* Override any gcc2 internal prototype to avoid an error. */
  9390. /* We use char because int might match the return type of a gcc2
  9391. builtin and then its argument prototype would still apply. */
  9392. char Tcl_Init();
  9393. int main() {
  9394. Tcl_Init()
  9395. ; return 0; }
  9396. EOF
  9397. if { (eval echo configure:11620: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9398. rm -rf conftest*
  9399. eval "ac_cv_lib_$ac_lib_var=yes"
  9400. else
  9401. echo "configure: failed program was:" >&5
  9402. cat conftest.$ac_ext >&5
  9403. rm -rf conftest*
  9404. eval "ac_cv_lib_$ac_lib_var=no"
  9405. fi
  9406. rm -f conftest*
  9407. LIBS="$ac_save_LIBS"
  9408. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9409. echo "$ac_t""yes" 1>&6
  9410. TCLLIB="$TCLLIB -ltcl$tcltk_ver2 $MATHLIB"
  9411. else
  9412. echo "$ac_t""no" 1>&6
  9413. echo $ac_n "checking for Tcl_Init in -ltcl$tcltk_ver2""... $ac_c" 1>&6
  9414. echo "configure:11639: checking for Tcl_Init in -ltcl$tcltk_ver2" >&5
  9415. ac_lib_var=`echo tcl$tcltk_ver2'_'Tcl_Init | sed 'y%./+-%__p_%'`
  9416. ac_save_LIBS="$LIBS"
  9417. LIBS="-ltcl$tcltk_ver2 $MATHLIB $DLLIB $LIBS"
  9418. cat > conftest.$ac_ext <<EOF
  9419. #line 11645 "configure"
  9420. #include "confdefs.h"
  9421. /* Override any gcc2 internal prototype to avoid an error. */
  9422. /* We use char because int might match the return type of a gcc2
  9423. builtin and then its argument prototype would still apply. */
  9424. char Tcl_Init();
  9425. int main() {
  9426. Tcl_Init()
  9427. ; return 0; }
  9428. EOF
  9429. if { (eval echo configure:11656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9430. rm -rf conftest*
  9431. eval "ac_cv_lib_$ac_lib_var=yes"
  9432. else
  9433. echo "configure: failed program was:" >&5
  9434. cat conftest.$ac_ext >&5
  9435. rm -rf conftest*
  9436. eval "ac_cv_lib_$ac_lib_var=no"
  9437. fi
  9438. rm -f conftest*
  9439. LIBS="$ac_save_LIBS"
  9440. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9441. echo "$ac_t""yes" 1>&6
  9442. TCLLIB="$TCLLIB -ltcl$tcltk_ver2 $MATHLIB $DLLIB"
  9443. else
  9444. echo "$ac_t""no" 1>&6
  9445. LDFLAGS=${ac_save_ldflags}
  9446. { echo "configure: error: *** Unable to locate Tcl library." 1>&2; exit 1; }
  9447. fi
  9448. fi
  9449. LDFLAGS=${ac_save_ldflags}
  9450. fi
  9451. fi
  9452. LDFLAGS=${ac_save_ldflags}
  9453. fi
  9454. fi
  9455. LDFLAGS=${ac_save_ldflags}
  9456. ac_save_ldflags="$LDFLAGS"
  9457. LDFLAGS="$TCLTKLIBPATH $LDFLAGS"
  9458. echo $ac_n "checking for Tk_MainWindow in -ltk""... $ac_c" 1>&6
  9459. echo "configure:11734: checking for Tk_MainWindow in -ltk" >&5
  9460. ac_lib_var=`echo tk'_'Tk_MainWindow | sed 'y%./+-%__p_%'`
  9461. ac_save_LIBS="$LIBS"
  9462. LIBS="-ltk $TCLLIB $MATHLIB $LIBS"
  9463. cat > conftest.$ac_ext <<EOF
  9464. #line 11740 "configure"
  9465. #include "confdefs.h"
  9466. /* Override any gcc2 internal prototype to avoid an error. */
  9467. /* We use char because int might match the return type of a gcc2
  9468. builtin and then its argument prototype would still apply. */
  9469. char Tk_MainWindow();
  9470. int main() {
  9471. Tk_MainWindow()
  9472. ; return 0; }
  9473. EOF
  9474. if { (eval echo configure:11751: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9475. rm -rf conftest*
  9476. eval "ac_cv_lib_$ac_lib_var=yes"
  9477. else
  9478. echo "configure: failed program was:" >&5
  9479. cat conftest.$ac_ext >&5
  9480. rm -rf conftest*
  9481. eval "ac_cv_lib_$ac_lib_var=no"
  9482. fi
  9483. rm -f conftest*
  9484. LIBS="$ac_save_LIBS"
  9485. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9486. echo "$ac_t""yes" 1>&6
  9487. TKLIB="$TKLIB -ltk $MATHLIB"
  9488. else
  9489. echo "$ac_t""no" 1>&6
  9490. echo $ac_n "checking for Tk_MainWindow in -ltk""... $ac_c" 1>&6
  9491. echo "configure:11770: checking for Tk_MainWindow in -ltk" >&5
  9492. ac_lib_var=`echo tk'_'Tk_MainWindow | sed 'y%./+-%__p_%'`
  9493. ac_save_LIBS="$LIBS"
  9494. LIBS="-ltk $TCLLIB $MATHLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
  9495. cat > conftest.$ac_ext <<EOF
  9496. #line 11776 "configure"
  9497. #include "confdefs.h"
  9498. /* Override any gcc2 internal prototype to avoid an error. */
  9499. /* We use char because int might match the return type of a gcc2
  9500. builtin and then its argument prototype would still apply. */
  9501. char Tk_MainWindow();
  9502. int main() {
  9503. Tk_MainWindow()
  9504. ; return 0; }
  9505. EOF
  9506. if { (eval echo configure:11787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9507. rm -rf conftest*
  9508. eval "ac_cv_lib_$ac_lib_var=yes"
  9509. else
  9510. echo "configure: failed program was:" >&5
  9511. cat conftest.$ac_ext >&5
  9512. rm -rf conftest*
  9513. eval "ac_cv_lib_$ac_lib_var=no"
  9514. fi
  9515. rm -f conftest*
  9516. LIBS="$ac_save_LIBS"
  9517. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9518. echo "$ac_t""yes" 1>&6
  9519. TKLIB="$TKLIB -ltk $MATHLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS"
  9520. else
  9521. echo "$ac_t""no" 1>&6
  9522. LDFLAGS=${ac_save_ldflags}
  9523. ac_save_ldflags="$LDFLAGS"
  9524. LDFLAGS="$TCLTKLIBPATH $LDFLAGS"
  9525. echo $ac_n "checking for Tk_MainWindow in -ltk$tcltk_ver""... $ac_c" 1>&6
  9526. echo "configure:11814: checking for Tk_MainWindow in -ltk$tcltk_ver" >&5
  9527. ac_lib_var=`echo tk$tcltk_ver'_'Tk_MainWindow | sed 'y%./+-%__p_%'`
  9528. ac_save_LIBS="$LIBS"
  9529. LIBS="-ltk$tcltk_ver $TCLLIB $MATHLIB $LIBS"
  9530. cat > conftest.$ac_ext <<EOF
  9531. #line 11820 "configure"
  9532. #include "confdefs.h"
  9533. /* Override any gcc2 internal prototype to avoid an error. */
  9534. /* We use char because int might match the return type of a gcc2
  9535. builtin and then its argument prototype would still apply. */
  9536. char Tk_MainWindow();
  9537. int main() {
  9538. Tk_MainWindow()
  9539. ; return 0; }
  9540. EOF
  9541. if { (eval echo configure:11831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9542. rm -rf conftest*
  9543. eval "ac_cv_lib_$ac_lib_var=yes"
  9544. else
  9545. echo "configure: failed program was:" >&5
  9546. cat conftest.$ac_ext >&5
  9547. rm -rf conftest*
  9548. eval "ac_cv_lib_$ac_lib_var=no"
  9549. fi
  9550. rm -f conftest*
  9551. LIBS="$ac_save_LIBS"
  9552. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9553. echo "$ac_t""yes" 1>&6
  9554. TKLIB="$TKLIB -ltk$tcltk_ver $MATHLIB"
  9555. else
  9556. echo "$ac_t""no" 1>&6
  9557. echo $ac_n "checking for Tk_MainWindow in -ltk$tcltk_ver""... $ac_c" 1>&6
  9558. echo "configure:11850: checking for Tk_MainWindow in -ltk$tcltk_ver" >&5
  9559. ac_lib_var=`echo tk$tcltk_ver'_'Tk_MainWindow | sed 'y%./+-%__p_%'`
  9560. ac_save_LIBS="$LIBS"
  9561. LIBS="-ltk$tcltk_ver $TCLLIB $MATHLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
  9562. cat > conftest.$ac_ext <<EOF
  9563. #line 11856 "configure"
  9564. #include "confdefs.h"
  9565. /* Override any gcc2 internal prototype to avoid an error. */
  9566. /* We use char because int might match the return type of a gcc2
  9567. builtin and then its argument prototype would still apply. */
  9568. char Tk_MainWindow();
  9569. int main() {
  9570. Tk_MainWindow()
  9571. ; return 0; }
  9572. EOF
  9573. if { (eval echo configure:11867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9574. rm -rf conftest*
  9575. eval "ac_cv_lib_$ac_lib_var=yes"
  9576. else
  9577. echo "configure: failed program was:" >&5
  9578. cat conftest.$ac_ext >&5
  9579. rm -rf conftest*
  9580. eval "ac_cv_lib_$ac_lib_var=no"
  9581. fi
  9582. rm -f conftest*
  9583. LIBS="$ac_save_LIBS"
  9584. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9585. echo "$ac_t""yes" 1>&6
  9586. TKLIB="$TKLIB -ltk$tcltk_ver $MATHLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS"
  9587. else
  9588. echo "$ac_t""no" 1>&6
  9589. LDFLAGS=${ac_save_ldflags}
  9590. ac_save_ldflags="$LDFLAGS"
  9591. LDFLAGS="$TCLTKLIBPATH $LDFLAGS"
  9592. echo $ac_n "checking for Tk_MainWindow in -ltk$tcltk_ver2""... $ac_c" 1>&6
  9593. echo "configure:11894: checking for Tk_MainWindow in -ltk$tcltk_ver2" >&5
  9594. ac_lib_var=`echo tk$tcltk_ver2'_'Tk_MainWindow | sed 'y%./+-%__p_%'`
  9595. ac_save_LIBS="$LIBS"
  9596. LIBS="-ltk$tcltk_ver2 $TCLLIB $MATHLIB $LIBS"
  9597. cat > conftest.$ac_ext <<EOF
  9598. #line 11900 "configure"
  9599. #include "confdefs.h"
  9600. /* Override any gcc2 internal prototype to avoid an error. */
  9601. /* We use char because int might match the return type of a gcc2
  9602. builtin and then its argument prototype would still apply. */
  9603. char Tk_MainWindow();
  9604. int main() {
  9605. Tk_MainWindow()
  9606. ; return 0; }
  9607. EOF
  9608. if { (eval echo configure:11911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9609. rm -rf conftest*
  9610. eval "ac_cv_lib_$ac_lib_var=yes"
  9611. else
  9612. echo "configure: failed program was:" >&5
  9613. cat conftest.$ac_ext >&5
  9614. rm -rf conftest*
  9615. eval "ac_cv_lib_$ac_lib_var=no"
  9616. fi
  9617. rm -f conftest*
  9618. LIBS="$ac_save_LIBS"
  9619. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9620. echo "$ac_t""yes" 1>&6
  9621. TKLIB="$TKLIB -ltk$tcltk_ver2 $MATHLIB"
  9622. else
  9623. echo "$ac_t""no" 1>&6
  9624. echo $ac_n "checking for Tk_MainWindow in -ltk$tcltk_ver2""... $ac_c" 1>&6
  9625. echo "configure:11930: checking for Tk_MainWindow in -ltk$tcltk_ver2" >&5
  9626. ac_lib_var=`echo tk$tcltk_ver2'_'Tk_MainWindow | sed 'y%./+-%__p_%'`
  9627. ac_save_LIBS="$LIBS"
  9628. LIBS="-ltk$tcltk_ver2 $TCLLIB $MATHLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
  9629. cat > conftest.$ac_ext <<EOF
  9630. #line 11936 "configure"
  9631. #include "confdefs.h"
  9632. /* Override any gcc2 internal prototype to avoid an error. */
  9633. /* We use char because int might match the return type of a gcc2
  9634. builtin and then its argument prototype would still apply. */
  9635. char Tk_MainWindow();
  9636. int main() {
  9637. Tk_MainWindow()
  9638. ; return 0; }
  9639. EOF
  9640. if { (eval echo configure:11947: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9641. rm -rf conftest*
  9642. eval "ac_cv_lib_$ac_lib_var=yes"
  9643. else
  9644. echo "configure: failed program was:" >&5
  9645. cat conftest.$ac_ext >&5
  9646. rm -rf conftest*
  9647. eval "ac_cv_lib_$ac_lib_var=no"
  9648. fi
  9649. rm -f conftest*
  9650. LIBS="$ac_save_LIBS"
  9651. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9652. echo "$ac_t""yes" 1>&6
  9653. TKLIB="$TKLIB -ltk$tcltk_ver2 $MATHLIB $X_LIBS $X_PRE_LIBS -lX11 $X_EXTRA_LIBS"
  9654. else
  9655. echo "$ac_t""no" 1>&6
  9656. LDFLAGS=${ac_save_ldflags}
  9657. { echo "configure: error: *** Unable to locate Tk library." 1>&2; exit 1; }
  9658. fi
  9659. fi
  9660. LDFLAGS=${ac_save_ldflags}
  9661. fi
  9662. fi
  9663. LDFLAGS=${ac_save_ldflags}
  9664. fi
  9665. fi
  9666. LDFLAGS=${ac_save_ldflags}
  9667. # restore CFLAGS/LDLFAGS from Aqua 64bit strip
  9668. # only Tcl/Tk-based makefiles will strip 64bit out during compile
  9669. if test "$OPENGL_AQUA" = 1 ; then
  9670. CFLAGS="$temp_CFLAGS"
  9671. LDFLAGS="$temp_ARCHES $LDFLAGS"
  9672. fi
  9673. TCLTKLIBS="$TKLIB $TCLLIB"
  9674. cat >> confdefs.h <<\EOF
  9675. #define HAVE_TCLTK 1
  9676. EOF
  9677. fi # $USE_TCLTK
  9678. TKINCDIR=$TCLINCDIR
  9679. # Done checking Tcl/Tk
  9680. # Enable ODBC option
  9681. echo $ac_n "checking whether to use ODBC""... $ac_c" 1>&6
  9682. echo "configure:12046: checking whether to use ODBC" >&5
  9683. echo "$ac_t"""$with_odbc"" 1>&6
  9684. case "$with_odbc" in
  9685. "no") USE_ODBC= ;;
  9686. "yes") USE_ODBC="1" ;;
  9687. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  9688. esac
  9689. ODBCINC=
  9690. ODBCLIB=
  9691. if test -n "$USE_ODBC"; then
  9692. # With ODBC includes directory
  9693. echo $ac_n "checking for location of ODBC includes""... $ac_c" 1>&6
  9694. echo "configure:12065: checking for location of ODBC includes" >&5
  9695. case "$with_odbc_includes" in
  9696. y | ye | yes | n | no)
  9697. { echo "configure: error: *** You must supply a directory to --with-odbc-includes." 1>&2; exit 1; }
  9698. ;;
  9699. esac
  9700. echo "$ac_t""$with_odbc_includes" 1>&6
  9701. if test -n "$with_odbc_includes" ; then
  9702. for dir in $with_odbc_includes; do
  9703. if test -d "$dir"; then
  9704. ODBCINC="$ODBCINC -I$dir"
  9705. else
  9706. { echo "configure: error: *** ODBC includes directory $dir does not exist." 1>&2; exit 1; }
  9707. fi
  9708. done
  9709. fi
  9710. ac_save_cppflags="$CPPFLAGS"
  9711. CPPFLAGS="$ODBCINC $CPPFLAGS"
  9712. for ac_hdr in sql.h
  9713. do
  9714. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  9715. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  9716. echo "configure:12091: checking for $ac_hdr" >&5
  9717. cat > conftest.$ac_ext <<EOF
  9718. #line 12094 "configure"
  9719. #include "confdefs.h"
  9720. #include <$ac_hdr>
  9721. EOF
  9722. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  9723. { (eval echo configure:12099: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  9724. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  9725. if test -z "$ac_err"; then
  9726. rm -rf conftest*
  9727. eval "ac_cv_header_$ac_safe=yes"
  9728. else
  9729. echo "$ac_err" >&5
  9730. echo "configure: failed program was:" >&5
  9731. cat conftest.$ac_ext >&5
  9732. rm -rf conftest*
  9733. eval "ac_cv_header_$ac_safe=no"
  9734. fi
  9735. rm -f conftest*
  9736. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  9737. echo "$ac_t""yes" 1>&6
  9738. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  9739. cat >> confdefs.h <<EOF
  9740. #define $ac_tr_hdr 1
  9741. EOF
  9742. else
  9743. echo "$ac_t""no" 1>&6
  9744. { echo "configure: error: *** Unable to locate ODBC includes." 1>&2; exit 1; }
  9745. fi
  9746. done
  9747. CPPFLAGS=$ac_save_cppflags
  9748. # With ODBC library directory
  9749. echo $ac_n "checking for location of ODBC library""... $ac_c" 1>&6
  9750. echo "configure:12133: checking for location of ODBC library" >&5
  9751. case "$with_odbc_libs" in
  9752. y | ye | yes | n | no)
  9753. { echo "configure: error: *** You must supply a directory to --with-odbc-libs." 1>&2; exit 1; }
  9754. ;;
  9755. esac
  9756. echo "$ac_t""$with_odbc_libs" 1>&6
  9757. if test -n "$with_odbc_libs"; then
  9758. for dir in $with_odbc_libs; do
  9759. if test -d "$dir"; then
  9760. ODBCLIB="$ODBCLIB -L$dir"
  9761. else
  9762. { echo "configure: error: *** ODBC library directory $dir does not exist." 1>&2; exit 1; }
  9763. fi
  9764. done
  9765. fi
  9766. ac_save_ldflags="$LDFLAGS"
  9767. LDFLAGS="$ODBCLIB $LDFLAGS"
  9768. echo $ac_n "checking for SQLConnect in -lodbc""... $ac_c" 1>&6
  9769. echo "configure:12158: checking for SQLConnect in -lodbc" >&5
  9770. ac_lib_var=`echo odbc'_'SQLConnect | sed 'y%./+-%__p_%'`
  9771. ac_save_LIBS="$LIBS"
  9772. LIBS="-lodbc $ICONVLIB $LIBS"
  9773. cat > conftest.$ac_ext <<EOF
  9774. #line 12164 "configure"
  9775. #include "confdefs.h"
  9776. /* Override any gcc2 internal prototype to avoid an error. */
  9777. /* We use char because int might match the return type of a gcc2
  9778. builtin and then its argument prototype would still apply. */
  9779. char SQLConnect();
  9780. int main() {
  9781. SQLConnect()
  9782. ; return 0; }
  9783. EOF
  9784. if { (eval echo configure:12175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9785. rm -rf conftest*
  9786. eval "ac_cv_lib_$ac_lib_var=yes"
  9787. else
  9788. echo "configure: failed program was:" >&5
  9789. cat conftest.$ac_ext >&5
  9790. rm -rf conftest*
  9791. eval "ac_cv_lib_$ac_lib_var=no"
  9792. fi
  9793. rm -f conftest*
  9794. LIBS="$ac_save_LIBS"
  9795. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9796. echo "$ac_t""yes" 1>&6
  9797. ODBCLIB="$ODBCLIB -lodbc "
  9798. else
  9799. echo "$ac_t""no" 1>&6
  9800. LDFLAGS=${ac_save_ldflags}
  9801. ac_save_ldflags="$LDFLAGS"
  9802. LDFLAGS="$ODBCLIB $LDFLAGS"
  9803. echo $ac_n "checking for SQLConnect in -liodbc""... $ac_c" 1>&6
  9804. echo "configure:12200: checking for SQLConnect in -liodbc" >&5
  9805. ac_lib_var=`echo iodbc'_'SQLConnect | sed 'y%./+-%__p_%'`
  9806. ac_save_LIBS="$LIBS"
  9807. LIBS="-liodbc $LIBS"
  9808. cat > conftest.$ac_ext <<EOF
  9809. #line 12206 "configure"
  9810. #include "confdefs.h"
  9811. /* Override any gcc2 internal prototype to avoid an error. */
  9812. /* We use char because int might match the return type of a gcc2
  9813. builtin and then its argument prototype would still apply. */
  9814. char SQLConnect();
  9815. int main() {
  9816. SQLConnect()
  9817. ; return 0; }
  9818. EOF
  9819. if { (eval echo configure:12217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9820. rm -rf conftest*
  9821. eval "ac_cv_lib_$ac_lib_var=yes"
  9822. else
  9823. echo "configure: failed program was:" >&5
  9824. cat conftest.$ac_ext >&5
  9825. rm -rf conftest*
  9826. eval "ac_cv_lib_$ac_lib_var=no"
  9827. fi
  9828. rm -f conftest*
  9829. LIBS="$ac_save_LIBS"
  9830. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  9831. echo "$ac_t""yes" 1>&6
  9832. ODBCLIB="$ODBCLIB -liodbc "
  9833. else
  9834. echo "$ac_t""no" 1>&6
  9835. LDFLAGS=${ac_save_ldflags}
  9836. ac_save_cflags="$CFLAGS"
  9837. CFLAGS="$CFLAGS $ODBCINC"
  9838. ac_save_ldflags="$LDFLAGS"
  9839. ac_save_libs="$LIBS"
  9840. echo $ac_n "checking for ODBC library""... $ac_c" 1>&6
  9841. echo "configure:12242: checking for ODBC library" >&5
  9842. LDFLAGS="$ODBCLIB $LDFLAGS"
  9843. LIBS="-lodbc32 "
  9844. cat > conftest.$ac_ext <<EOF
  9845. #line 12246 "configure"
  9846. #include "confdefs.h"
  9847. #include <windows.h>
  9848. #include <sql.h>
  9849. int main() {
  9850. SQLAllocEnv((SQLHENV *)0);
  9851. ; return 0; }
  9852. EOF
  9853. if { (eval echo configure:12254: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  9854. rm -rf conftest*
  9855. echo "$ac_t""found" 1>&6
  9856. ODBCLIB="$ODBCLIB -lodbc32 "
  9857. else
  9858. echo "configure: failed program was:" >&5
  9859. cat conftest.$ac_ext >&5
  9860. rm -rf conftest*
  9861. { echo "configure: error: *** Unable to locate ODBC library." 1>&2; exit 1; }
  9862. fi
  9863. rm -f conftest*
  9864. LIBS=${ac_save_libs}
  9865. LDFLAGS=${ac_save_ldflags}
  9866. CFLAGS=${ac_save_cflags}
  9867. fi
  9868. LDFLAGS=${ac_save_ldflags}
  9869. fi
  9870. LDFLAGS=${ac_save_ldflags}
  9871. fi # $USE_ODBC
  9872. # Done checking ODBC
  9873. # Enable FFTW option
  9874. echo $ac_n "checking whether to use FFTW""... $ac_c" 1>&6
  9875. echo "configure:12303: checking whether to use FFTW" >&5
  9876. echo "$ac_t"""$with_fftw"" 1>&6
  9877. case "$with_fftw" in
  9878. "no") USE_FFTW= ;;
  9879. "yes") USE_FFTW="1" ;;
  9880. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  9881. esac
  9882. FFTWINC=
  9883. FFTWLIB=
  9884. if test -n "$USE_FFTW"; then
  9885. # With FFTW includes directory
  9886. echo $ac_n "checking for location of FFTW includes""... $ac_c" 1>&6
  9887. echo "configure:12322: checking for location of FFTW includes" >&5
  9888. case "$with_fftw_includes" in
  9889. y | ye | yes | n | no)
  9890. { echo "configure: error: *** You must supply a directory to --with-fftw-includes." 1>&2; exit 1; }
  9891. ;;
  9892. esac
  9893. echo "$ac_t""$with_fftw_includes" 1>&6
  9894. if test -n "$with_fftw_includes" ; then
  9895. for dir in $with_fftw_includes; do
  9896. if test -d "$dir"; then
  9897. FFTWINC="$FFTWINC -I$dir"
  9898. else
  9899. { echo "configure: error: *** FFTW includes directory $dir does not exist." 1>&2; exit 1; }
  9900. fi
  9901. done
  9902. fi
  9903. ac_save_cppflags="$CPPFLAGS"
  9904. CPPFLAGS="$FFTWINC $CPPFLAGS"
  9905. for ac_hdr in fftw3.h
  9906. do
  9907. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  9908. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  9909. echo "configure:12348: checking for $ac_hdr" >&5
  9910. cat > conftest.$ac_ext <<EOF
  9911. #line 12351 "configure"
  9912. #include "confdefs.h"
  9913. #include <$ac_hdr>
  9914. EOF
  9915. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  9916. { (eval echo configure:12356: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  9917. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  9918. if test -z "$ac_err"; then
  9919. rm -rf conftest*
  9920. eval "ac_cv_header_$ac_safe=yes"
  9921. else
  9922. echo "$ac_err" >&5
  9923. echo "configure: failed program was:" >&5
  9924. cat conftest.$ac_ext >&5
  9925. rm -rf conftest*
  9926. eval "ac_cv_header_$ac_safe=no"
  9927. fi
  9928. rm -f conftest*
  9929. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  9930. echo "$ac_t""yes" 1>&6
  9931. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  9932. cat >> confdefs.h <<EOF
  9933. #define $ac_tr_hdr 1
  9934. EOF
  9935. else
  9936. echo "$ac_t""no" 1>&6
  9937. ac_save_cppflags="$CPPFLAGS"
  9938. CPPFLAGS=" $CPPFLAGS"
  9939. for ac_hdr in fftw.h
  9940. do
  9941. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  9942. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  9943. echo "configure:12384: checking for $ac_hdr" >&5
  9944. cat > conftest.$ac_ext <<EOF
  9945. #line 12387 "configure"
  9946. #include "confdefs.h"
  9947. #include <$ac_hdr>
  9948. EOF
  9949. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  9950. { (eval echo configure:12392: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  9951. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  9952. if test -z "$ac_err"; then
  9953. rm -rf conftest*
  9954. eval "ac_cv_header_$ac_safe=yes"
  9955. else
  9956. echo "$ac_err" >&5
  9957. echo "configure: failed program was:" >&5
  9958. cat conftest.$ac_ext >&5
  9959. rm -rf conftest*
  9960. eval "ac_cv_header_$ac_safe=no"
  9961. fi
  9962. rm -f conftest*
  9963. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  9964. echo "$ac_t""yes" 1>&6
  9965. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  9966. cat >> confdefs.h <<EOF
  9967. #define $ac_tr_hdr 1
  9968. EOF
  9969. else
  9970. echo "$ac_t""no" 1>&6
  9971. ac_save_cppflags="$CPPFLAGS"
  9972. CPPFLAGS=" $CPPFLAGS"
  9973. for ac_hdr in dfftw.h
  9974. do
  9975. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  9976. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  9977. echo "configure:12420: checking for $ac_hdr" >&5
  9978. cat > conftest.$ac_ext <<EOF
  9979. #line 12423 "configure"
  9980. #include "confdefs.h"
  9981. #include <$ac_hdr>
  9982. EOF
  9983. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  9984. { (eval echo configure:12428: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  9985. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  9986. if test -z "$ac_err"; then
  9987. rm -rf conftest*
  9988. eval "ac_cv_header_$ac_safe=yes"
  9989. else
  9990. echo "$ac_err" >&5
  9991. echo "configure: failed program was:" >&5
  9992. cat conftest.$ac_ext >&5
  9993. rm -rf conftest*
  9994. eval "ac_cv_header_$ac_safe=no"
  9995. fi
  9996. rm -f conftest*
  9997. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  9998. echo "$ac_t""yes" 1>&6
  9999. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  10000. cat >> confdefs.h <<EOF
  10001. #define $ac_tr_hdr 1
  10002. EOF
  10003. else
  10004. echo "$ac_t""no" 1>&6
  10005. { echo "configure: error: *** Unable to locate FFTW includes." 1>&2; exit 1; }
  10006. fi
  10007. done
  10008. CPPFLAGS=$ac_save_cppflags
  10009. fi
  10010. done
  10011. CPPFLAGS=$ac_save_cppflags
  10012. fi
  10013. done
  10014. CPPFLAGS=$ac_save_cppflags
  10015. # With FFTW library directory
  10016. echo $ac_n "checking for location of FFTW library""... $ac_c" 1>&6
  10017. echo "configure:12474: checking for location of FFTW library" >&5
  10018. case "$with_fftw_libs" in
  10019. y | ye | yes | n | no)
  10020. { echo "configure: error: *** You must supply a directory to --with-fftw-libs." 1>&2; exit 1; }
  10021. ;;
  10022. esac
  10023. echo "$ac_t""$with_fftw_libs" 1>&6
  10024. if test -n "$with_fftw_libs"; then
  10025. for dir in $with_fftw_libs; do
  10026. if test -d "$dir"; then
  10027. FFTWLIB="$FFTWLIB -L$dir"
  10028. else
  10029. { echo "configure: error: *** FFTW library directory $dir does not exist." 1>&2; exit 1; }
  10030. fi
  10031. done
  10032. fi
  10033. ac_save_ldflags="$LDFLAGS"
  10034. LDFLAGS="$FFTWLIB $LDFLAGS"
  10035. echo $ac_n "checking for fftw_execute in -lfftw3""... $ac_c" 1>&6
  10036. echo "configure:12499: checking for fftw_execute in -lfftw3" >&5
  10037. ac_lib_var=`echo fftw3'_'fftw_execute | sed 'y%./+-%__p_%'`
  10038. ac_save_LIBS="$LIBS"
  10039. LIBS="-lfftw3 $MATHLIB $LIBS"
  10040. cat > conftest.$ac_ext <<EOF
  10041. #line 12505 "configure"
  10042. #include "confdefs.h"
  10043. /* Override any gcc2 internal prototype to avoid an error. */
  10044. /* We use char because int might match the return type of a gcc2
  10045. builtin and then its argument prototype would still apply. */
  10046. char fftw_execute();
  10047. int main() {
  10048. fftw_execute()
  10049. ; return 0; }
  10050. EOF
  10051. if { (eval echo configure:12516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10052. rm -rf conftest*
  10053. eval "ac_cv_lib_$ac_lib_var=yes"
  10054. else
  10055. echo "configure: failed program was:" >&5
  10056. cat conftest.$ac_ext >&5
  10057. rm -rf conftest*
  10058. eval "ac_cv_lib_$ac_lib_var=no"
  10059. fi
  10060. rm -f conftest*
  10061. LIBS="$ac_save_LIBS"
  10062. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10063. echo "$ac_t""yes" 1>&6
  10064. FFTWLIB="$FFTWLIB -lfftw3 $MATHLIB"
  10065. else
  10066. echo "$ac_t""no" 1>&6
  10067. LDFLAGS=${ac_save_ldflags}
  10068. ac_save_ldflags="$LDFLAGS"
  10069. LDFLAGS="$FFTWLIB $LDFLAGS"
  10070. echo $ac_n "checking for fftwnd_one in -lfftw""... $ac_c" 1>&6
  10071. echo "configure:12541: checking for fftwnd_one in -lfftw" >&5
  10072. ac_lib_var=`echo fftw'_'fftwnd_one | sed 'y%./+-%__p_%'`
  10073. ac_save_LIBS="$LIBS"
  10074. LIBS="-lfftw $MATHLIB $LIBS"
  10075. cat > conftest.$ac_ext <<EOF
  10076. #line 12547 "configure"
  10077. #include "confdefs.h"
  10078. /* Override any gcc2 internal prototype to avoid an error. */
  10079. /* We use char because int might match the return type of a gcc2
  10080. builtin and then its argument prototype would still apply. */
  10081. char fftwnd_one();
  10082. int main() {
  10083. fftwnd_one()
  10084. ; return 0; }
  10085. EOF
  10086. if { (eval echo configure:12558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10087. rm -rf conftest*
  10088. eval "ac_cv_lib_$ac_lib_var=yes"
  10089. else
  10090. echo "configure: failed program was:" >&5
  10091. cat conftest.$ac_ext >&5
  10092. rm -rf conftest*
  10093. eval "ac_cv_lib_$ac_lib_var=no"
  10094. fi
  10095. rm -f conftest*
  10096. LIBS="$ac_save_LIBS"
  10097. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10098. echo "$ac_t""yes" 1>&6
  10099. FFTWLIB="$FFTWLIB -lfftw $MATHLIB"
  10100. else
  10101. echo "$ac_t""no" 1>&6
  10102. LDFLAGS=${ac_save_ldflags}
  10103. ac_save_ldflags="$LDFLAGS"
  10104. LDFLAGS="$FFTWLIB $LDFLAGS"
  10105. echo $ac_n "checking for fftwnd_one in -ldfftw""... $ac_c" 1>&6
  10106. echo "configure:12583: checking for fftwnd_one in -ldfftw" >&5
  10107. ac_lib_var=`echo dfftw'_'fftwnd_one | sed 'y%./+-%__p_%'`
  10108. ac_save_LIBS="$LIBS"
  10109. LIBS="-ldfftw $MATHLIB $LIBS"
  10110. cat > conftest.$ac_ext <<EOF
  10111. #line 12589 "configure"
  10112. #include "confdefs.h"
  10113. /* Override any gcc2 internal prototype to avoid an error. */
  10114. /* We use char because int might match the return type of a gcc2
  10115. builtin and then its argument prototype would still apply. */
  10116. char fftwnd_one();
  10117. int main() {
  10118. fftwnd_one()
  10119. ; return 0; }
  10120. EOF
  10121. if { (eval echo configure:12600: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10122. rm -rf conftest*
  10123. eval "ac_cv_lib_$ac_lib_var=yes"
  10124. else
  10125. echo "configure: failed program was:" >&5
  10126. cat conftest.$ac_ext >&5
  10127. rm -rf conftest*
  10128. eval "ac_cv_lib_$ac_lib_var=no"
  10129. fi
  10130. rm -f conftest*
  10131. LIBS="$ac_save_LIBS"
  10132. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10133. echo "$ac_t""yes" 1>&6
  10134. FFTWLIB="$FFTWLIB -ldfftw $MATHLIB"
  10135. else
  10136. echo "$ac_t""no" 1>&6
  10137. LDFLAGS=${ac_save_ldflags}
  10138. { echo "configure: error: *** Unable to locate FFTW library." 1>&2; exit 1; }
  10139. fi
  10140. LDFLAGS=${ac_save_ldflags}
  10141. fi
  10142. LDFLAGS=${ac_save_ldflags}
  10143. fi
  10144. LDFLAGS=${ac_save_ldflags}
  10145. fi # $USE_FFTW
  10146. # Done checking FFTW
  10147. # Enable BLAS option
  10148. echo $ac_n "checking whether to use BLAS""... $ac_c" 1>&6
  10149. echo "configure:12657: checking whether to use BLAS" >&5
  10150. echo "$ac_t"""$with_blas"" 1>&6
  10151. case "$with_blas" in
  10152. "no") USE_BLAS= ;;
  10153. "yes") USE_BLAS="1" ;;
  10154. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  10155. esac
  10156. BLASLIB=
  10157. BLASINC=
  10158. if test -n "$USE_BLAS"; then
  10159. # With BLAS includes directory
  10160. # BLAS doesn't have includes (FORTRAN library)
  10161. # With BLAS library directory
  10162. echo $ac_n "checking for location of BLAS includes""... $ac_c" 1>&6
  10163. echo "configure:12678: checking for location of BLAS includes" >&5
  10164. case "$with_blas_includes" in
  10165. y | ye | yes | n | no)
  10166. { echo "configure: error: *** You must supply a directory to --with-blas-includes." 1>&2; exit 1; }
  10167. ;;
  10168. esac
  10169. echo "$ac_t""$with_blas_includes" 1>&6
  10170. if test -n "$with_blas_includes" ; then
  10171. for dir in $with_blas_includes; do
  10172. if test -d "$dir"; then
  10173. BLASINC="$BLASINC -I$dir"
  10174. else
  10175. { echo "configure: error: *** BLAS includes directory $dir does not exist." 1>&2; exit 1; }
  10176. fi
  10177. done
  10178. fi
  10179. echo $ac_n "checking for location of BLAS library""... $ac_c" 1>&6
  10180. echo "configure:12698: checking for location of BLAS library" >&5
  10181. case "$with_blas_libs" in
  10182. y | ye | yes | n | no)
  10183. { echo "configure: error: *** You must supply a directory to --with-blas-libs." 1>&2; exit 1; }
  10184. ;;
  10185. esac
  10186. echo "$ac_t""$with_blas_libs" 1>&6
  10187. if test -n "$with_blas_libs"; then
  10188. for dir in $with_blas_libs; do
  10189. if test -d "$dir"; then
  10190. BLASLIB="$BLASLIB -L$dir"
  10191. else
  10192. { echo "configure: error: *** BLAS library directory $dir does not exist." 1>&2; exit 1; }
  10193. fi
  10194. done
  10195. fi
  10196. # See if cblas.h exists (CBLAS,ATLAS,others)
  10197. save_CPPFLAGS="$CPPFLAGS"
  10198. CPPFLAGS="$BLASINC $CPPFLAGS"
  10199. for ac_hdr in cblas.h
  10200. do
  10201. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  10202. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  10203. echo "configure:12724: checking for $ac_hdr" >&5
  10204. cat > conftest.$ac_ext <<EOF
  10205. #line 12727 "configure"
  10206. #include "confdefs.h"
  10207. #include <$ac_hdr>
  10208. EOF
  10209. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  10210. { (eval echo configure:12732: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  10211. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  10212. if test -z "$ac_err"; then
  10213. rm -rf conftest*
  10214. eval "ac_cv_header_$ac_safe=yes"
  10215. else
  10216. echo "$ac_err" >&5
  10217. echo "configure: failed program was:" >&5
  10218. cat conftest.$ac_ext >&5
  10219. rm -rf conftest*
  10220. eval "ac_cv_header_$ac_safe=no"
  10221. fi
  10222. rm -f conftest*
  10223. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  10224. echo "$ac_t""yes" 1>&6
  10225. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  10226. cat >> confdefs.h <<EOF
  10227. #define $ac_tr_hdr 1
  10228. EOF
  10229. else
  10230. echo "$ac_t""no" 1>&6
  10231. fi
  10232. done
  10233. CPPFLAGS=$save_CPPFLAGS
  10234. ac_save_ldflags="$LDFLAGS"
  10235. LDFLAGS="$BLASLIB $LDFLAGS"
  10236. echo $ac_n "checking for dnrm2_ in -lblas""... $ac_c" 1>&6
  10237. echo "configure:12767: checking for dnrm2_ in -lblas" >&5
  10238. ac_lib_var=`echo blas'_'dnrm2_ | sed 'y%./+-%__p_%'`
  10239. ac_save_LIBS="$LIBS"
  10240. LIBS="-lblas $MATHLIB $LIBS"
  10241. cat > conftest.$ac_ext <<EOF
  10242. #line 12773 "configure"
  10243. #include "confdefs.h"
  10244. /* Override any gcc2 internal prototype to avoid an error. */
  10245. /* We use char because int might match the return type of a gcc2
  10246. builtin and then its argument prototype would still apply. */
  10247. char dnrm2_();
  10248. int main() {
  10249. dnrm2_()
  10250. ; return 0; }
  10251. EOF
  10252. if { (eval echo configure:12784: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10253. rm -rf conftest*
  10254. eval "ac_cv_lib_$ac_lib_var=yes"
  10255. else
  10256. echo "configure: failed program was:" >&5
  10257. cat conftest.$ac_ext >&5
  10258. rm -rf conftest*
  10259. eval "ac_cv_lib_$ac_lib_var=no"
  10260. fi
  10261. rm -f conftest*
  10262. LIBS="$ac_save_LIBS"
  10263. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10264. echo "$ac_t""yes" 1>&6
  10265. BLASLIB="$BLASLIB -lblas "
  10266. else
  10267. echo "$ac_t""no" 1>&6
  10268. echo $ac_n "checking for dnrm2_ in -lblas""... $ac_c" 1>&6
  10269. echo "configure:12803: checking for dnrm2_ in -lblas" >&5
  10270. ac_lib_var=`echo blas'_'dnrm2_ | sed 'y%./+-%__p_%'`
  10271. ac_save_LIBS="$LIBS"
  10272. LIBS="-lblas $MATHLIB -lg2c $LIBS"
  10273. cat > conftest.$ac_ext <<EOF
  10274. #line 12809 "configure"
  10275. #include "confdefs.h"
  10276. /* Override any gcc2 internal prototype to avoid an error. */
  10277. /* We use char because int might match the return type of a gcc2
  10278. builtin and then its argument prototype would still apply. */
  10279. char dnrm2_();
  10280. int main() {
  10281. dnrm2_()
  10282. ; return 0; }
  10283. EOF
  10284. if { (eval echo configure:12820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10285. rm -rf conftest*
  10286. eval "ac_cv_lib_$ac_lib_var=yes"
  10287. else
  10288. echo "configure: failed program was:" >&5
  10289. cat conftest.$ac_ext >&5
  10290. rm -rf conftest*
  10291. eval "ac_cv_lib_$ac_lib_var=no"
  10292. fi
  10293. rm -f conftest*
  10294. LIBS="$ac_save_LIBS"
  10295. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10296. echo "$ac_t""yes" 1>&6
  10297. BLASLIB="$BLASLIB -lblas -lg2c"
  10298. else
  10299. echo "$ac_t""no" 1>&6
  10300. LDFLAGS=${ac_save_ldflags}
  10301. { echo "configure: error: *** Unable to locate BLAS library." 1>&2; exit 1; }
  10302. fi
  10303. fi
  10304. LDFLAGS=${ac_save_ldflags}
  10305. blas_ok=no
  10306. # Check for ATLAS
  10307. save_LDFLAGS="$LDFLAGS"
  10308. LDFLAGS="$BLASLIB $LDFLAGS"
  10309. echo $ac_n "checking for ATL_xerbla in -latlas""... $ac_c" 1>&6
  10310. echo "configure:12864: checking for ATL_xerbla in -latlas" >&5
  10311. ac_lib_var=`echo atlas'_'ATL_xerbla | sed 'y%./+-%__p_%'`
  10312. ac_save_LIBS="$LIBS"
  10313. LIBS="-latlas $LIBS"
  10314. cat > conftest.$ac_ext <<EOF
  10315. #line 12870 "configure"
  10316. #include "confdefs.h"
  10317. /* Override any gcc2 internal prototype to avoid an error. */
  10318. /* We use char because int might match the return type of a gcc2
  10319. builtin and then its argument prototype would still apply. */
  10320. char ATL_xerbla();
  10321. int main() {
  10322. ATL_xerbla()
  10323. ; return 0; }
  10324. EOF
  10325. if { (eval echo configure:12881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10326. rm -rf conftest*
  10327. eval "ac_cv_lib_$ac_lib_var=yes"
  10328. else
  10329. echo "configure: failed program was:" >&5
  10330. cat conftest.$ac_ext >&5
  10331. rm -rf conftest*
  10332. eval "ac_cv_lib_$ac_lib_var=no"
  10333. fi
  10334. rm -f conftest*
  10335. LIBS="$ac_save_LIBS"
  10336. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10337. echo "$ac_t""yes" 1>&6
  10338. echo $ac_n "checking for sgemm_ in -lf77blas""... $ac_c" 1>&6
  10339. echo "configure:12896: checking for sgemm_ in -lf77blas" >&5
  10340. ac_lib_var=`echo f77blas'_'sgemm_ | sed 'y%./+-%__p_%'`
  10341. ac_save_LIBS="$LIBS"
  10342. LIBS="-lf77blas -latlas $LIBS"
  10343. cat > conftest.$ac_ext <<EOF
  10344. #line 12902 "configure"
  10345. #include "confdefs.h"
  10346. /* Override any gcc2 internal prototype to avoid an error. */
  10347. /* We use char because int might match the return type of a gcc2
  10348. builtin and then its argument prototype would still apply. */
  10349. char sgemm_();
  10350. int main() {
  10351. sgemm_()
  10352. ; return 0; }
  10353. EOF
  10354. if { (eval echo configure:12913: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10355. rm -rf conftest*
  10356. eval "ac_cv_lib_$ac_lib_var=yes"
  10357. else
  10358. echo "configure: failed program was:" >&5
  10359. cat conftest.$ac_ext >&5
  10360. rm -rf conftest*
  10361. eval "ac_cv_lib_$ac_lib_var=no"
  10362. fi
  10363. rm -f conftest*
  10364. LIBS="$ac_save_LIBS"
  10365. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10366. echo "$ac_t""yes" 1>&6
  10367. echo $ac_n "checking for cblas_dgemm in -lcblas""... $ac_c" 1>&6
  10368. echo "configure:12928: checking for cblas_dgemm in -lcblas" >&5
  10369. ac_lib_var=`echo cblas'_'cblas_dgemm | sed 'y%./+-%__p_%'`
  10370. ac_save_LIBS="$LIBS"
  10371. LIBS="-lcblas -lf77blas -latlas $LIBS"
  10372. cat > conftest.$ac_ext <<EOF
  10373. #line 12934 "configure"
  10374. #include "confdefs.h"
  10375. /* Override any gcc2 internal prototype to avoid an error. */
  10376. /* We use char because int might match the return type of a gcc2
  10377. builtin and then its argument prototype would still apply. */
  10378. char cblas_dgemm();
  10379. int main() {
  10380. cblas_dgemm()
  10381. ; return 0; }
  10382. EOF
  10383. if { (eval echo configure:12945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10384. rm -rf conftest*
  10385. eval "ac_cv_lib_$ac_lib_var=yes"
  10386. else
  10387. echo "configure: failed program was:" >&5
  10388. cat conftest.$ac_ext >&5
  10389. rm -rf conftest*
  10390. eval "ac_cv_lib_$ac_lib_var=no"
  10391. fi
  10392. rm -f conftest*
  10393. LIBS="$ac_save_LIBS"
  10394. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10395. echo "$ac_t""yes" 1>&6
  10396. blas_ok=yes; BLASLIB="-lcblas -lf77blas -latlas"
  10397. else
  10398. echo "$ac_t""no" 1>&6
  10399. fi
  10400. else
  10401. echo "$ac_t""no" 1>&6
  10402. fi
  10403. else
  10404. echo "$ac_t""no" 1>&6
  10405. fi
  10406. LDFLAGS="$save_LDFLAGS"
  10407. # Do we have ATLAS?
  10408. if test $blas_ok = yes; then
  10409. cat >> confdefs.h <<\EOF
  10410. #define HAVE_LIBATLAS 1
  10411. EOF
  10412. fi
  10413. # BLAS in Apple vecLib framework? (Mac OS-X)
  10414. if test -n "$MACOSX_APP"; then
  10415. if test $blas_ok = no; then
  10416. vlib_flags="-framework vecLib"
  10417. save_LIBS="$LIBS"
  10418. LIBS="$vlib_flags $LIBS"
  10419. echo $ac_n "checking for sgemm in $vlib_flags""... $ac_c" 1>&6
  10420. echo "configure:12990: checking for sgemm in $vlib_flags" >&5
  10421. cat > conftest.$ac_ext <<EOF
  10422. #line 12992 "configure"
  10423. #include "confdefs.h"
  10424. int main() {
  10425. sgemm
  10426. ; return 0; }
  10427. EOF
  10428. if { (eval echo configure:12999: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10429. rm -rf conftest*
  10430. blas_ok=yes; BLASLIB="$vlib_flags"
  10431. else
  10432. echo "configure: failed program was:" >&5
  10433. cat conftest.$ac_ext >&5
  10434. rm -rf conftest*
  10435. BLASLIB=""
  10436. fi
  10437. rm -f conftest*
  10438. echo "$ac_t""$blas_ok" 1>&6
  10439. LIBS="$save_LIBS"
  10440. fi
  10441. fi # $MACOSX_APP
  10442. # BLAS in PhiPACK libraries? (requires generic BLAS, too)
  10443. if test $blas_ok = no; then
  10444. echo $ac_n "checking for sgemm_ in -lblas""... $ac_c" 1>&6
  10445. echo "configure:13017: checking for sgemm_ in -lblas" >&5
  10446. ac_lib_var=`echo blas'_'sgemm_ | sed 'y%./+-%__p_%'`
  10447. ac_save_LIBS="$LIBS"
  10448. LIBS="-lblas $LIBS"
  10449. cat > conftest.$ac_ext <<EOF
  10450. #line 13023 "configure"
  10451. #include "confdefs.h"
  10452. /* Override any gcc2 internal prototype to avoid an error. */
  10453. /* We use char because int might match the return type of a gcc2
  10454. builtin and then its argument prototype would still apply. */
  10455. char sgemm_();
  10456. int main() {
  10457. sgemm_()
  10458. ; return 0; }
  10459. EOF
  10460. if { (eval echo configure:13034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10461. rm -rf conftest*
  10462. eval "ac_cv_lib_$ac_lib_var=yes"
  10463. else
  10464. echo "configure: failed program was:" >&5
  10465. cat conftest.$ac_ext >&5
  10466. rm -rf conftest*
  10467. eval "ac_cv_lib_$ac_lib_var=no"
  10468. fi
  10469. rm -f conftest*
  10470. LIBS="$ac_save_LIBS"
  10471. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10472. echo "$ac_t""yes" 1>&6
  10473. echo $ac_n "checking for dgemm_ in -ldgemm""... $ac_c" 1>&6
  10474. echo "configure:13049: checking for dgemm_ in -ldgemm" >&5
  10475. ac_lib_var=`echo dgemm'_'dgemm_ | sed 'y%./+-%__p_%'`
  10476. ac_save_LIBS="$LIBS"
  10477. LIBS="-ldgemm -lblas $LIBS"
  10478. cat > conftest.$ac_ext <<EOF
  10479. #line 13055 "configure"
  10480. #include "confdefs.h"
  10481. /* Override any gcc2 internal prototype to avoid an error. */
  10482. /* We use char because int might match the return type of a gcc2
  10483. builtin and then its argument prototype would still apply. */
  10484. char dgemm_();
  10485. int main() {
  10486. dgemm_()
  10487. ; return 0; }
  10488. EOF
  10489. if { (eval echo configure:13066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10490. rm -rf conftest*
  10491. eval "ac_cv_lib_$ac_lib_var=yes"
  10492. else
  10493. echo "configure: failed program was:" >&5
  10494. cat conftest.$ac_ext >&5
  10495. rm -rf conftest*
  10496. eval "ac_cv_lib_$ac_lib_var=no"
  10497. fi
  10498. rm -f conftest*
  10499. LIBS="$ac_save_LIBS"
  10500. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10501. echo "$ac_t""yes" 1>&6
  10502. echo $ac_n "checking for sgemm_ in -lsgemm""... $ac_c" 1>&6
  10503. echo "configure:13081: checking for sgemm_ in -lsgemm" >&5
  10504. ac_lib_var=`echo sgemm'_'sgemm_ | sed 'y%./+-%__p_%'`
  10505. ac_save_LIBS="$LIBS"
  10506. LIBS="-lsgemm -lblas $LIBS"
  10507. cat > conftest.$ac_ext <<EOF
  10508. #line 13087 "configure"
  10509. #include "confdefs.h"
  10510. /* Override any gcc2 internal prototype to avoid an error. */
  10511. /* We use char because int might match the return type of a gcc2
  10512. builtin and then its argument prototype would still apply. */
  10513. char sgemm_();
  10514. int main() {
  10515. sgemm_()
  10516. ; return 0; }
  10517. EOF
  10518. if { (eval echo configure:13098: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10519. rm -rf conftest*
  10520. eval "ac_cv_lib_$ac_lib_var=yes"
  10521. else
  10522. echo "configure: failed program was:" >&5
  10523. cat conftest.$ac_ext >&5
  10524. rm -rf conftest*
  10525. eval "ac_cv_lib_$ac_lib_var=no"
  10526. fi
  10527. rm -f conftest*
  10528. LIBS="$ac_save_LIBS"
  10529. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10530. echo "$ac_t""yes" 1>&6
  10531. blas_ok=yes; BLASLIB="-lsgemm -ldgemm -lblas"
  10532. else
  10533. echo "$ac_t""no" 1>&6
  10534. fi
  10535. else
  10536. echo "$ac_t""no" 1>&6
  10537. fi
  10538. else
  10539. echo "$ac_t""no" 1>&6
  10540. fi
  10541. fi
  10542. # BLAS in Sun Performance library?
  10543. if test $blas_ok = no; then
  10544. if test "x$GCC" != xyes; then # only works with Sun CC
  10545. echo $ac_n "checking for acosp in -lsunmath""... $ac_c" 1>&6
  10546. echo "configure:13132: checking for acosp in -lsunmath" >&5
  10547. ac_lib_var=`echo sunmath'_'acosp | sed 'y%./+-%__p_%'`
  10548. ac_save_LIBS="$LIBS"
  10549. LIBS="-lsunmath $LIBS"
  10550. cat > conftest.$ac_ext <<EOF
  10551. #line 13138 "configure"
  10552. #include "confdefs.h"
  10553. /* Override any gcc2 internal prototype to avoid an error. */
  10554. /* We use char because int might match the return type of a gcc2
  10555. builtin and then its argument prototype would still apply. */
  10556. char acosp();
  10557. int main() {
  10558. acosp()
  10559. ; return 0; }
  10560. EOF
  10561. if { (eval echo configure:13149: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10562. rm -rf conftest*
  10563. eval "ac_cv_lib_$ac_lib_var=yes"
  10564. else
  10565. echo "configure: failed program was:" >&5
  10566. cat conftest.$ac_ext >&5
  10567. rm -rf conftest*
  10568. eval "ac_cv_lib_$ac_lib_var=no"
  10569. fi
  10570. rm -f conftest*
  10571. LIBS="$ac_save_LIBS"
  10572. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10573. echo "$ac_t""yes" 1>&6
  10574. echo $ac_n "checking for sgemm_ in -lsunperf""... $ac_c" 1>&6
  10575. echo "configure:13164: checking for sgemm_ in -lsunperf" >&5
  10576. ac_lib_var=`echo sunperf'_'sgemm_ | sed 'y%./+-%__p_%'`
  10577. ac_save_LIBS="$LIBS"
  10578. LIBS="-lsunperf -lsunmath $LIBS"
  10579. cat > conftest.$ac_ext <<EOF
  10580. #line 13170 "configure"
  10581. #include "confdefs.h"
  10582. /* Override any gcc2 internal prototype to avoid an error. */
  10583. /* We use char because int might match the return type of a gcc2
  10584. builtin and then its argument prototype would still apply. */
  10585. char sgemm_();
  10586. int main() {
  10587. sgemm_()
  10588. ; return 0; }
  10589. EOF
  10590. if { (eval echo configure:13181: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10591. rm -rf conftest*
  10592. eval "ac_cv_lib_$ac_lib_var=yes"
  10593. else
  10594. echo "configure: failed program was:" >&5
  10595. cat conftest.$ac_ext >&5
  10596. rm -rf conftest*
  10597. eval "ac_cv_lib_$ac_lib_var=no"
  10598. fi
  10599. rm -f conftest*
  10600. LIBS="$ac_save_LIBS"
  10601. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10602. echo "$ac_t""yes" 1>&6
  10603. blas_ok=yes; BLASLIB="-xlic_lib=sunperf -lsunmath"
  10604. else
  10605. echo "$ac_t""no" 1>&6
  10606. fi
  10607. else
  10608. echo "$ac_t""no" 1>&6
  10609. fi
  10610. fi
  10611. fi
  10612. # Generic BLAS library
  10613. if test $blas_ok = no; then
  10614. echo $ac_n "checking for sgemm_ in -lblas""... $ac_c" 1>&6
  10615. echo "configure:13211: checking for sgemm_ in -lblas" >&5
  10616. ac_lib_var=`echo blas'_'sgemm_ | sed 'y%./+-%__p_%'`
  10617. ac_save_LIBS="$LIBS"
  10618. LIBS="-lblas $LIBS"
  10619. cat > conftest.$ac_ext <<EOF
  10620. #line 13217 "configure"
  10621. #include "confdefs.h"
  10622. /* Override any gcc2 internal prototype to avoid an error. */
  10623. /* We use char because int might match the return type of a gcc2
  10624. builtin and then its argument prototype would still apply. */
  10625. char sgemm_();
  10626. int main() {
  10627. sgemm_()
  10628. ; return 0; }
  10629. EOF
  10630. if { (eval echo configure:13228: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10631. rm -rf conftest*
  10632. eval "ac_cv_lib_$ac_lib_var=yes"
  10633. else
  10634. echo "configure: failed program was:" >&5
  10635. cat conftest.$ac_ext >&5
  10636. rm -rf conftest*
  10637. eval "ac_cv_lib_$ac_lib_var=no"
  10638. fi
  10639. rm -f conftest*
  10640. LIBS="$ac_save_LIBS"
  10641. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10642. echo "$ac_t""yes" 1>&6
  10643. blas_ok=yes; BLASLIB="-lblas"
  10644. else
  10645. echo "$ac_t""no" 1>&6
  10646. fi
  10647. fi
  10648. if test $blas_ok = yes; then
  10649. cat >> confdefs.h <<\EOF
  10650. #define HAVE_LIBBLAS 1
  10651. EOF
  10652. fi
  10653. fi # $USE_BLAS
  10654. # Done checking BLAS
  10655. # Enable LAPACK option
  10656. echo $ac_n "checking whether to use LAPACK""... $ac_c" 1>&6
  10657. echo "configure:13267: checking whether to use LAPACK" >&5
  10658. echo "$ac_t"""$with_lapack"" 1>&6
  10659. case "$with_lapack" in
  10660. "no") USE_LAPACK= ;;
  10661. "yes") USE_LAPACK="1" ;;
  10662. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  10663. esac
  10664. LAPACKLIB=
  10665. LAPACKINC=
  10666. # LAPACK is useless without BLAS
  10667. if test -n "$USE_BLAS"; then
  10668. if test -n "$USE_LAPACK"; then
  10669. # With LAPACK includes directory
  10670. # LAPACK doesn't have includes (FORTRAN library)
  10671. # With LAPACK library directory
  10672. lapack_ok=no
  10673. echo $ac_n "checking for location of LAPACK includes""... $ac_c" 1>&6
  10674. echo "configure:13292: checking for location of LAPACK includes" >&5
  10675. case "$with_lapack_includes" in
  10676. y | ye | yes | n | no)
  10677. { echo "configure: error: *** You must supply a directory to --with-lapack-includes." 1>&2; exit 1; }
  10678. ;;
  10679. esac
  10680. echo "$ac_t""$with_lapack_includes" 1>&6
  10681. if test -n "$with_lapack_includes" ; then
  10682. for dir in $with_lapack_includes; do
  10683. if test -d "$dir"; then
  10684. LAPACKINC="$LAPACKINC -I$dir"
  10685. else
  10686. { echo "configure: error: *** LAPACK includes directory $dir does not exist." 1>&2; exit 1; }
  10687. fi
  10688. done
  10689. fi
  10690. echo $ac_n "checking for location of LAPACK library""... $ac_c" 1>&6
  10691. echo "configure:13312: checking for location of LAPACK library" >&5
  10692. case "$with_lapack_libs" in
  10693. y | ye | yes | n | no)
  10694. { echo "configure: error: *** You must supply a directory to --with-lapack-libs." 1>&2; exit 1; }
  10695. ;;
  10696. esac
  10697. echo "$ac_t""$with_lapack_libs" 1>&6
  10698. if test -n "$with_lapack_libs"; then
  10699. for dir in $with_lapack_libs; do
  10700. if test -d "$dir"; then
  10701. LAPACKLIB="$LAPACKLIB -L$dir"
  10702. else
  10703. { echo "configure: error: *** LAPACK library directory $dir does not exist." 1>&2; exit 1; }
  10704. fi
  10705. done
  10706. fi
  10707. # See if clapack.h exists (ATLAS)
  10708. save_CPPFLAGS="$CPPFLAGS"
  10709. CPPFLAGS="$LAPACKINC $CPPFLAGS"
  10710. for ac_hdr in clapack.h
  10711. do
  10712. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  10713. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  10714. echo "configure:13338: checking for $ac_hdr" >&5
  10715. cat > conftest.$ac_ext <<EOF
  10716. #line 13341 "configure"
  10717. #include "confdefs.h"
  10718. #include <$ac_hdr>
  10719. EOF
  10720. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  10721. { (eval echo configure:13346: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  10722. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  10723. if test -z "$ac_err"; then
  10724. rm -rf conftest*
  10725. eval "ac_cv_header_$ac_safe=yes"
  10726. else
  10727. echo "$ac_err" >&5
  10728. echo "configure: failed program was:" >&5
  10729. cat conftest.$ac_ext >&5
  10730. rm -rf conftest*
  10731. eval "ac_cv_header_$ac_safe=no"
  10732. fi
  10733. rm -f conftest*
  10734. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  10735. echo "$ac_t""yes" 1>&6
  10736. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  10737. cat >> confdefs.h <<EOF
  10738. #define $ac_tr_hdr 1
  10739. EOF
  10740. else
  10741. echo "$ac_t""no" 1>&6
  10742. fi
  10743. done
  10744. CPPFLAGS=$save_CPPFLAGS
  10745. # LAPACK linked to by default?
  10746. if test lapack_ok=no; then
  10747. save_LIBS="$LIBS"; LIBS="$LIBS $BLASLIB $MATHLIB $FLIBS"
  10748. save_LDFLAGS="$LDFLAGS"; LDFLAGS="$LAPACKLIB $LDFLAGS"
  10749. echo $ac_n "checking for dsegv_""... $ac_c" 1>&6
  10750. echo "configure:13378: checking for dsegv_" >&5
  10751. cat > conftest.$ac_ext <<EOF
  10752. #line 13381 "configure"
  10753. #include "confdefs.h"
  10754. /* System header to define __stub macros and hopefully few prototypes,
  10755. which can conflict with char dsegv_(); below. */
  10756. #include <assert.h>
  10757. /* Override any gcc2 internal prototype to avoid an error. */
  10758. /* We use char because int might match the return type of a gcc2
  10759. builtin and then its argument prototype would still apply. */
  10760. char dsegv_();
  10761. int main() {
  10762. /* The GNU C library defines this for functions which it implements
  10763. to always fail with ENOSYS. Some functions are actually named
  10764. something starting with __ and the normal name is an alias. */
  10765. #if defined (__stub_dsegv_) || defined (__stub___dsegv_)
  10766. choke me
  10767. #else
  10768. dsegv_();
  10769. #endif
  10770. ; return 0; }
  10771. EOF
  10772. if { (eval echo configure:13404: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10773. rm -rf conftest*
  10774. eval "ac_cv_func_dsegv_=yes"
  10775. else
  10776. echo "configure: failed program was:" >&5
  10777. cat conftest.$ac_ext >&5
  10778. rm -rf conftest*
  10779. eval "ac_cv_func_dsegv_=no"
  10780. fi
  10781. rm -f conftest*
  10782. if eval "test \"`echo '$ac_cv_func_'dsegv_`\" = yes"; then
  10783. echo "$ac_t""yes" 1>&6
  10784. lapack_ok=yes
  10785. else
  10786. echo "$ac_t""no" 1>&6
  10787. fi
  10788. LIBS="$save_LIBS"
  10789. LDFLAGS="$save_LDFLAGS"
  10790. fi
  10791. # Generic LAPACK library?
  10792. if test $lapack_ok = no; then
  10793. save_libs="$LIBS"; LIBS="$BLASLIB $MATHLIB $LIBS"
  10794. save_LDFLAGS="$LDFLAGS"; LDFLAGS="$LAPACKLIB $LDFLAGS"
  10795. echo $ac_n "checking for desgv_ in -llapack""... $ac_c" 1>&6
  10796. echo "configure:13431: checking for desgv_ in -llapack" >&5
  10797. ac_lib_var=`echo lapack'_'desgv_ | sed 'y%./+-%__p_%'`
  10798. ac_save_LIBS="$LIBS"
  10799. LIBS="-llapack $FLIBS $LIBS"
  10800. cat > conftest.$ac_ext <<EOF
  10801. #line 13437 "configure"
  10802. #include "confdefs.h"
  10803. /* Override any gcc2 internal prototype to avoid an error. */
  10804. /* We use char because int might match the return type of a gcc2
  10805. builtin and then its argument prototype would still apply. */
  10806. char desgv_();
  10807. int main() {
  10808. desgv_()
  10809. ; return 0; }
  10810. EOF
  10811. if { (eval echo configure:13448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10812. rm -rf conftest*
  10813. eval "ac_cv_lib_$ac_lib_var=yes"
  10814. else
  10815. echo "configure: failed program was:" >&5
  10816. cat conftest.$ac_ext >&5
  10817. rm -rf conftest*
  10818. eval "ac_cv_lib_$ac_lib_var=no"
  10819. fi
  10820. rm -f conftest*
  10821. LIBS="$ac_save_LIBS"
  10822. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10823. echo "$ac_t""yes" 1>&6
  10824. lapack_ok=yes; LAPACKLIB="-llapack"
  10825. else
  10826. echo "$ac_t""no" 1>&6
  10827. fi
  10828. LIBS="$save_LIBS"
  10829. LDFLAGS="$save_LDFLAGS"
  10830. fi
  10831. if test $lapack_ok = no; then
  10832. ac_save_ldflags="$LDFLAGS"
  10833. LDFLAGS="$LAPACKLIB $LDFLAGS"
  10834. echo $ac_n "checking for dgesv_ in -llapack""... $ac_c" 1>&6
  10835. echo "configure:13480: checking for dgesv_ in -llapack" >&5
  10836. ac_lib_var=`echo lapack'_'dgesv_ | sed 'y%./+-%__p_%'`
  10837. ac_save_LIBS="$LIBS"
  10838. LIBS="-llapack $BLASLIB $MATHLIB $LIBS"
  10839. cat > conftest.$ac_ext <<EOF
  10840. #line 13486 "configure"
  10841. #include "confdefs.h"
  10842. /* Override any gcc2 internal prototype to avoid an error. */
  10843. /* We use char because int might match the return type of a gcc2
  10844. builtin and then its argument prototype would still apply. */
  10845. char dgesv_();
  10846. int main() {
  10847. dgesv_()
  10848. ; return 0; }
  10849. EOF
  10850. if { (eval echo configure:13497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10851. rm -rf conftest*
  10852. eval "ac_cv_lib_$ac_lib_var=yes"
  10853. else
  10854. echo "configure: failed program was:" >&5
  10855. cat conftest.$ac_ext >&5
  10856. rm -rf conftest*
  10857. eval "ac_cv_lib_$ac_lib_var=no"
  10858. fi
  10859. rm -f conftest*
  10860. LIBS="$ac_save_LIBS"
  10861. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10862. echo "$ac_t""yes" 1>&6
  10863. LAPACKLIB="$LAPACKLIB -llapack "
  10864. else
  10865. echo "$ac_t""no" 1>&6
  10866. echo $ac_n "checking for dgesv_ in -llapack""... $ac_c" 1>&6
  10867. echo "configure:13516: checking for dgesv_ in -llapack" >&5
  10868. ac_lib_var=`echo lapack'_'dgesv_ | sed 'y%./+-%__p_%'`
  10869. ac_save_LIBS="$LIBS"
  10870. LIBS="-llapack $BLASLIB $MATHLIB -lg2c $LIBS"
  10871. cat > conftest.$ac_ext <<EOF
  10872. #line 13522 "configure"
  10873. #include "confdefs.h"
  10874. /* Override any gcc2 internal prototype to avoid an error. */
  10875. /* We use char because int might match the return type of a gcc2
  10876. builtin and then its argument prototype would still apply. */
  10877. char dgesv_();
  10878. int main() {
  10879. dgesv_()
  10880. ; return 0; }
  10881. EOF
  10882. if { (eval echo configure:13533: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  10883. rm -rf conftest*
  10884. eval "ac_cv_lib_$ac_lib_var=yes"
  10885. else
  10886. echo "configure: failed program was:" >&5
  10887. cat conftest.$ac_ext >&5
  10888. rm -rf conftest*
  10889. eval "ac_cv_lib_$ac_lib_var=no"
  10890. fi
  10891. rm -f conftest*
  10892. LIBS="$ac_save_LIBS"
  10893. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  10894. echo "$ac_t""yes" 1>&6
  10895. LAPACKLIB="$LAPACKLIB -llapack -lg2c"
  10896. else
  10897. echo "$ac_t""no" 1>&6
  10898. LDFLAGS=${ac_save_ldflags}
  10899. { echo "configure: error: *** Unable to locate LAPACK library." 1>&2; exit 1; }
  10900. fi
  10901. fi
  10902. LDFLAGS=${ac_save_ldflags}
  10903. fi
  10904. cat >> confdefs.h <<\EOF
  10905. #define HAVE_LIBLAPACK 1
  10906. EOF
  10907. fi # $USE_LAPACK
  10908. fi # $USE_BLAS
  10909. # Done checking LAPACK
  10910. # Enable Cairo display driver option
  10911. echo $ac_n "checking whether to use Cairo""... $ac_c" 1>&6
  10912. echo "configure:13589: checking whether to use Cairo" >&5
  10913. echo "$ac_t"""$with_cairo"" 1>&6
  10914. case "$with_cairo" in
  10915. "no") USE_CAIRO= ;;
  10916. "yes") USE_CAIRO="1" ;;
  10917. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  10918. esac
  10919. CAIROINC=
  10920. CAIROLIB=
  10921. if test -n "$USE_CAIRO"; then
  10922. cairo="cairo cairo-ft"
  10923. if test -n "$USE_X11"; then
  10924. cairo="$cairo cairo-xlib-xrender"
  10925. fi
  10926. # With Cairo includes directory
  10927. CAIROINC=`pkg-config --cflags $cairo`
  10928. echo $ac_n "checking for location of cairo includes""... $ac_c" 1>&6
  10929. echo "configure:13615: checking for location of cairo includes" >&5
  10930. case "$with_cairo_includes" in
  10931. y | ye | yes | n | no)
  10932. { echo "configure: error: *** You must supply a directory to --with-cairo-includes." 1>&2; exit 1; }
  10933. ;;
  10934. esac
  10935. echo "$ac_t""$with_cairo_includes" 1>&6
  10936. if test -n "$with_cairo_includes" ; then
  10937. for dir in $with_cairo_includes; do
  10938. if test -d "$dir"; then
  10939. CAIROINC="$CAIROINC -I$dir"
  10940. else
  10941. { echo "configure: error: *** cairo includes directory $dir does not exist." 1>&2; exit 1; }
  10942. fi
  10943. done
  10944. fi
  10945. ac_save_cppflags="$CPPFLAGS"
  10946. CPPFLAGS="$CAIROINC $CPPFLAGS"
  10947. for ac_hdr in cairo.h
  10948. do
  10949. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  10950. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  10951. echo "configure:13641: checking for $ac_hdr" >&5
  10952. cat > conftest.$ac_ext <<EOF
  10953. #line 13644 "configure"
  10954. #include "confdefs.h"
  10955. #include <$ac_hdr>
  10956. EOF
  10957. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  10958. { (eval echo configure:13649: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  10959. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  10960. if test -z "$ac_err"; then
  10961. rm -rf conftest*
  10962. eval "ac_cv_header_$ac_safe=yes"
  10963. else
  10964. echo "$ac_err" >&5
  10965. echo "configure: failed program was:" >&5
  10966. cat conftest.$ac_ext >&5
  10967. rm -rf conftest*
  10968. eval "ac_cv_header_$ac_safe=no"
  10969. fi
  10970. rm -f conftest*
  10971. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  10972. echo "$ac_t""yes" 1>&6
  10973. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  10974. cat >> confdefs.h <<EOF
  10975. #define $ac_tr_hdr 1
  10976. EOF
  10977. else
  10978. echo "$ac_t""no" 1>&6
  10979. { echo "configure: error: *** Unable to locate Cairo includes." 1>&2; exit 1; }
  10980. fi
  10981. done
  10982. CPPFLAGS=$ac_save_cppflags
  10983. # With Cairo library directory
  10984. CAIROLIB=`pkg-config --libs $cairo`
  10985. echo $ac_n "checking for location of cairo library""... $ac_c" 1>&6
  10986. echo "configure:13685: checking for location of cairo library" >&5
  10987. case "$with_cairo_libs" in
  10988. y | ye | yes | n | no)
  10989. { echo "configure: error: *** You must supply a directory to --with-cairo-libs." 1>&2; exit 1; }
  10990. ;;
  10991. esac
  10992. echo "$ac_t""$with_cairo_libs" 1>&6
  10993. if test -n "$with_cairo_libs"; then
  10994. for dir in $with_cairo_libs; do
  10995. if test -d "$dir"; then
  10996. CAIROLIB="$CAIROLIB -L$dir"
  10997. else
  10998. { echo "configure: error: *** cairo library directory $dir does not exist." 1>&2; exit 1; }
  10999. fi
  11000. done
  11001. fi
  11002. echo $ac_n "checking for cairo linking flags""... $ac_c" 1>&6
  11003. echo "configure:13705: checking for cairo linking flags" >&5
  11004. case "$with_cairo_ldflags" in
  11005. y | ye | yes | n | no)
  11006. { echo "configure: error: *** You must supply a directory to --with-cairo-ldflags." 1>&2; exit 1; }
  11007. ;;
  11008. esac
  11009. echo "$ac_t""$with_cairo_ldflags" 1>&6
  11010. CAIROLIB="$CAIROLIB $with_cairo_ldflags"
  11011. ac_save_libs="$LIBS"
  11012. ac_save_ldflags="$LDFLAGS"
  11013. LIBS=" $CAIROLIB $LIBS"
  11014. LDFLAGS=" $LDFLAGS"
  11015. echo $ac_n "checking for cairo_create""... $ac_c" 1>&6
  11016. echo "configure:13721: checking for cairo_create" >&5
  11017. cat > conftest.$ac_ext <<EOF
  11018. #line 13724 "configure"
  11019. #include "confdefs.h"
  11020. /* System header to define __stub macros and hopefully few prototypes,
  11021. which can conflict with char cairo_create(); below. */
  11022. #include <assert.h>
  11023. /* Override any gcc2 internal prototype to avoid an error. */
  11024. /* We use char because int might match the return type of a gcc2
  11025. builtin and then its argument prototype would still apply. */
  11026. char cairo_create();
  11027. int main() {
  11028. /* The GNU C library defines this for functions which it implements
  11029. to always fail with ENOSYS. Some functions are actually named
  11030. something starting with __ and the normal name is an alias. */
  11031. #if defined (__stub_cairo_create) || defined (__stub___cairo_create)
  11032. choke me
  11033. #else
  11034. cairo_create();
  11035. #endif
  11036. ; return 0; }
  11037. EOF
  11038. if { (eval echo configure:13747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11039. rm -rf conftest*
  11040. eval "ac_cv_func_cairo_create=yes"
  11041. else
  11042. echo "configure: failed program was:" >&5
  11043. cat conftest.$ac_ext >&5
  11044. rm -rf conftest*
  11045. eval "ac_cv_func_cairo_create=no"
  11046. fi
  11047. rm -f conftest*
  11048. if eval "test \"`echo '$ac_cv_func_'cairo_create`\" = yes"; then
  11049. echo "$ac_t""yes" 1>&6
  11050. :
  11051. else
  11052. echo "$ac_t""no" 1>&6
  11053. { echo "configure: error: *** Unable to locate ." 1>&2; exit 1; }
  11054. fi
  11055. LIBS=${ac_save_libs}
  11056. LDFLAGS=${ac_save_ldflags}
  11057. ac_save_libs="$LIBS"
  11058. ac_save_ldflags="$LDFLAGS"
  11059. LIBS=" $CAIROLIB $LIBS"
  11060. LDFLAGS=" $LDFLAGS"
  11061. echo $ac_n "checking for cairo_xlib_surface_create_with_xrender_format""... $ac_c" 1>&6
  11062. echo "configure:13781: checking for cairo_xlib_surface_create_with_xrender_format" >&5
  11063. cat > conftest.$ac_ext <<EOF
  11064. #line 13784 "configure"
  11065. #include "confdefs.h"
  11066. /* System header to define __stub macros and hopefully few prototypes,
  11067. which can conflict with char cairo_xlib_surface_create_with_xrender_format(); below. */
  11068. #include <assert.h>
  11069. /* Override any gcc2 internal prototype to avoid an error. */
  11070. /* We use char because int might match the return type of a gcc2
  11071. builtin and then its argument prototype would still apply. */
  11072. char cairo_xlib_surface_create_with_xrender_format();
  11073. int main() {
  11074. /* The GNU C library defines this for functions which it implements
  11075. to always fail with ENOSYS. Some functions are actually named
  11076. something starting with __ and the normal name is an alias. */
  11077. #if defined (__stub_cairo_xlib_surface_create_with_xrender_format) || defined (__stub___cairo_xlib_surface_create_with_xrender_format)
  11078. choke me
  11079. #else
  11080. cairo_xlib_surface_create_with_xrender_format();
  11081. #endif
  11082. ; return 0; }
  11083. EOF
  11084. if { (eval echo configure:13807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11085. rm -rf conftest*
  11086. eval "ac_cv_func_cairo_xlib_surface_create_with_xrender_format=yes"
  11087. else
  11088. echo "configure: failed program was:" >&5
  11089. cat conftest.$ac_ext >&5
  11090. rm -rf conftest*
  11091. eval "ac_cv_func_cairo_xlib_surface_create_with_xrender_format=no"
  11092. fi
  11093. rm -f conftest*
  11094. if eval "test \"`echo '$ac_cv_func_'cairo_xlib_surface_create_with_xrender_format`\" = yes"; then
  11095. echo "$ac_t""yes" 1>&6
  11096. CAIRO_HAS_XRENDER=1
  11097. else
  11098. echo "$ac_t""no" 1>&6
  11099. CAIRO_HAS_XRENDER=
  11100. fi
  11101. LIBS=${ac_save_libs}
  11102. LDFLAGS=${ac_save_ldflags}
  11103. ac_save_libs="$LIBS"
  11104. ac_save_ldflags="$LDFLAGS"
  11105. LIBS=" $CAIROLIB $LIBS"
  11106. LDFLAGS=" $LDFLAGS"
  11107. echo $ac_n "checking for cairo_xlib_surface_get_xrender_format""... $ac_c" 1>&6
  11108. echo "configure:13840: checking for cairo_xlib_surface_get_xrender_format" >&5
  11109. cat > conftest.$ac_ext <<EOF
  11110. #line 13843 "configure"
  11111. #include "confdefs.h"
  11112. /* System header to define __stub macros and hopefully few prototypes,
  11113. which can conflict with char cairo_xlib_surface_get_xrender_format(); below. */
  11114. #include <assert.h>
  11115. /* Override any gcc2 internal prototype to avoid an error. */
  11116. /* We use char because int might match the return type of a gcc2
  11117. builtin and then its argument prototype would still apply. */
  11118. char cairo_xlib_surface_get_xrender_format();
  11119. int main() {
  11120. /* The GNU C library defines this for functions which it implements
  11121. to always fail with ENOSYS. Some functions are actually named
  11122. something starting with __ and the normal name is an alias. */
  11123. #if defined (__stub_cairo_xlib_surface_get_xrender_format) || defined (__stub___cairo_xlib_surface_get_xrender_format)
  11124. choke me
  11125. #else
  11126. cairo_xlib_surface_get_xrender_format();
  11127. #endif
  11128. ; return 0; }
  11129. EOF
  11130. if { (eval echo configure:13866: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11131. rm -rf conftest*
  11132. eval "ac_cv_func_cairo_xlib_surface_get_xrender_format=yes"
  11133. else
  11134. echo "configure: failed program was:" >&5
  11135. cat conftest.$ac_ext >&5
  11136. rm -rf conftest*
  11137. eval "ac_cv_func_cairo_xlib_surface_get_xrender_format=no"
  11138. fi
  11139. rm -f conftest*
  11140. if eval "test \"`echo '$ac_cv_func_'cairo_xlib_surface_get_xrender_format`\" = yes"; then
  11141. echo "$ac_t""yes" 1>&6
  11142. CAIRO_HAS_XRENDER_SURFACE=1
  11143. else
  11144. echo "$ac_t""no" 1>&6
  11145. CAIRO_HAS_XRENDER_SURFACE=
  11146. fi
  11147. LIBS=${ac_save_libs}
  11148. LDFLAGS=${ac_save_ldflags}
  11149. CAIROLIB="$CAIROLIB $CAIROLDFLAGS"
  11150. fi # $USE_CAIRO
  11151. # Done checking Cairo
  11152. # Enable FreeType option
  11153. echo $ac_n "checking whether to use FreeType""... $ac_c" 1>&6
  11154. echo "configure:13908: checking whether to use FreeType" >&5
  11155. echo "$ac_t"""$with_freetype"" 1>&6
  11156. case "$with_freetype" in
  11157. "no") USE_FREETYPE= ;;
  11158. "yes") USE_FREETYPE="1" ;;
  11159. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  11160. esac
  11161. FTINC=
  11162. FTLIB=
  11163. if test -n "$USE_FREETYPE"; then
  11164. # With FreeType includes directory
  11165. echo $ac_n "checking for location of FreeType includes""... $ac_c" 1>&6
  11166. echo "configure:13927: checking for location of FreeType includes" >&5
  11167. case "$with_freetype_includes" in
  11168. y | ye | yes | n | no)
  11169. { echo "configure: error: *** You must supply a directory to --with-freetype-includes." 1>&2; exit 1; }
  11170. ;;
  11171. esac
  11172. echo "$ac_t""$with_freetype_includes" 1>&6
  11173. if test -n "$with_freetype_includes" ; then
  11174. for dir in $with_freetype_includes; do
  11175. if test -d "$dir"; then
  11176. FTINC="$FTINC -I$dir"
  11177. else
  11178. { echo "configure: error: *** FreeType includes directory $dir does not exist." 1>&2; exit 1; }
  11179. fi
  11180. done
  11181. fi
  11182. ac_save_cppflags="$CPPFLAGS"
  11183. CPPFLAGS="$FTINC $CPPFLAGS"
  11184. for ac_hdr in ft2build.h
  11185. do
  11186. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  11187. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  11188. echo "configure:13953: checking for $ac_hdr" >&5
  11189. cat > conftest.$ac_ext <<EOF
  11190. #line 13956 "configure"
  11191. #include "confdefs.h"
  11192. #include <$ac_hdr>
  11193. EOF
  11194. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  11195. { (eval echo configure:13961: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  11196. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  11197. if test -z "$ac_err"; then
  11198. rm -rf conftest*
  11199. eval "ac_cv_header_$ac_safe=yes"
  11200. else
  11201. echo "$ac_err" >&5
  11202. echo "configure: failed program was:" >&5
  11203. cat conftest.$ac_ext >&5
  11204. rm -rf conftest*
  11205. eval "ac_cv_header_$ac_safe=no"
  11206. fi
  11207. rm -f conftest*
  11208. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  11209. echo "$ac_t""yes" 1>&6
  11210. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  11211. cat >> confdefs.h <<EOF
  11212. #define $ac_tr_hdr 1
  11213. EOF
  11214. else
  11215. echo "$ac_t""no" 1>&6
  11216. { echo "configure: error: *** Unable to locate FreeType includes." 1>&2; exit 1; }
  11217. fi
  11218. done
  11219. CPPFLAGS=$ac_save_cppflags
  11220. # With FreeType library directory
  11221. echo $ac_n "checking for location of FreeType library""... $ac_c" 1>&6
  11222. echo "configure:13995: checking for location of FreeType library" >&5
  11223. case "$with_freetype_libs" in
  11224. y | ye | yes | n | no)
  11225. { echo "configure: error: *** You must supply a directory to --with-freetype-libs." 1>&2; exit 1; }
  11226. ;;
  11227. esac
  11228. echo "$ac_t""$with_freetype_libs" 1>&6
  11229. if test -n "$with_freetype_libs"; then
  11230. for dir in $with_freetype_libs; do
  11231. if test -d "$dir"; then
  11232. FTLIB="$FTLIB -L$dir"
  11233. else
  11234. { echo "configure: error: *** FreeType library directory $dir does not exist." 1>&2; exit 1; }
  11235. fi
  11236. done
  11237. fi
  11238. ac_save_ldflags="$LDFLAGS"
  11239. LDFLAGS="$FTLIB $LDFLAGS"
  11240. echo $ac_n "checking for FT_Init_FreeType in -lfreetype""... $ac_c" 1>&6
  11241. echo "configure:14020: checking for FT_Init_FreeType in -lfreetype" >&5
  11242. ac_lib_var=`echo freetype'_'FT_Init_FreeType | sed 'y%./+-%__p_%'`
  11243. ac_save_LIBS="$LIBS"
  11244. LIBS="-lfreetype $LIBS"
  11245. cat > conftest.$ac_ext <<EOF
  11246. #line 14026 "configure"
  11247. #include "confdefs.h"
  11248. /* Override any gcc2 internal prototype to avoid an error. */
  11249. /* We use char because int might match the return type of a gcc2
  11250. builtin and then its argument prototype would still apply. */
  11251. char FT_Init_FreeType();
  11252. int main() {
  11253. FT_Init_FreeType()
  11254. ; return 0; }
  11255. EOF
  11256. if { (eval echo configure:14037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11257. rm -rf conftest*
  11258. eval "ac_cv_lib_$ac_lib_var=yes"
  11259. else
  11260. echo "configure: failed program was:" >&5
  11261. cat conftest.$ac_ext >&5
  11262. rm -rf conftest*
  11263. eval "ac_cv_lib_$ac_lib_var=no"
  11264. fi
  11265. rm -f conftest*
  11266. LIBS="$ac_save_LIBS"
  11267. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  11268. echo "$ac_t""yes" 1>&6
  11269. FTLIB="$FTLIB -lfreetype "
  11270. else
  11271. echo "$ac_t""no" 1>&6
  11272. LDFLAGS=${ac_save_ldflags}
  11273. { echo "configure: error: *** Unable to locate FreeType library." 1>&2; exit 1; }
  11274. fi
  11275. LDFLAGS=${ac_save_ldflags}
  11276. fi # $USE_FREETYPE
  11277. # Done checking FreeType
  11278. # Enable NLS option
  11279. echo $ac_n "checking whether to use NLS""... $ac_c" 1>&6
  11280. echo "configure:14078: checking whether to use NLS" >&5
  11281. echo "$ac_t"""$with_nls"" 1>&6
  11282. case "$with_nls" in
  11283. "no") USE_NLS= ;;
  11284. "yes") USE_NLS="1" ;;
  11285. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  11286. esac
  11287. INTLLIB=
  11288. HAVE_NLS=
  11289. if test -n "${USE_NLS}" ; then
  11290. cat >> confdefs.h <<\EOF
  11291. #define USE_NLS 1
  11292. EOF
  11293. echo $ac_n "checking for gettext""... $ac_c" 1>&6
  11294. echo "configure:14098: checking for gettext" >&5
  11295. cat > conftest.$ac_ext <<EOF
  11296. #line 14101 "configure"
  11297. #include "confdefs.h"
  11298. /* System header to define __stub macros and hopefully few prototypes,
  11299. which can conflict with char gettext(); below. */
  11300. #include <assert.h>
  11301. /* Override any gcc2 internal prototype to avoid an error. */
  11302. /* We use char because int might match the return type of a gcc2
  11303. builtin and then its argument prototype would still apply. */
  11304. char gettext();
  11305. int main() {
  11306. /* The GNU C library defines this for functions which it implements
  11307. to always fail with ENOSYS. Some functions are actually named
  11308. something starting with __ and the normal name is an alias. */
  11309. #if defined (__stub_gettext) || defined (__stub___gettext)
  11310. choke me
  11311. #else
  11312. gettext();
  11313. #endif
  11314. ; return 0; }
  11315. EOF
  11316. if { (eval echo configure:14124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11317. rm -rf conftest*
  11318. eval "ac_cv_func_gettext=yes"
  11319. else
  11320. echo "configure: failed program was:" >&5
  11321. cat conftest.$ac_ext >&5
  11322. rm -rf conftest*
  11323. eval "ac_cv_func_gettext=no"
  11324. fi
  11325. rm -f conftest*
  11326. if eval "test \"`echo '$ac_cv_func_'gettext`\" = yes"; then
  11327. echo "$ac_t""yes" 1>&6
  11328. INTLLIB=
  11329. else
  11330. echo "$ac_t""no" 1>&6
  11331. echo $ac_n "checking for gettext in -lintl""... $ac_c" 1>&6
  11332. echo "configure:14142: checking for gettext in -lintl" >&5
  11333. ac_lib_var=`echo intl'_'gettext | sed 'y%./+-%__p_%'`
  11334. ac_save_LIBS="$LIBS"
  11335. LIBS="-lintl $LIBS"
  11336. cat > conftest.$ac_ext <<EOF
  11337. #line 14148 "configure"
  11338. #include "confdefs.h"
  11339. /* Override any gcc2 internal prototype to avoid an error. */
  11340. /* We use char because int might match the return type of a gcc2
  11341. builtin and then its argument prototype would still apply. */
  11342. char gettext();
  11343. int main() {
  11344. gettext()
  11345. ; return 0; }
  11346. EOF
  11347. if { (eval echo configure:14159: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11348. rm -rf conftest*
  11349. eval "ac_cv_lib_$ac_lib_var=yes"
  11350. else
  11351. echo "configure: failed program was:" >&5
  11352. cat conftest.$ac_ext >&5
  11353. rm -rf conftest*
  11354. eval "ac_cv_lib_$ac_lib_var=no"
  11355. fi
  11356. rm -f conftest*
  11357. LIBS="$ac_save_LIBS"
  11358. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  11359. echo "$ac_t""yes" 1>&6
  11360. INTLLIB=-lintl
  11361. else
  11362. echo "$ac_t""no" 1>&6
  11363. { echo "configure: error: *** Unable to locate gettext() function." 1>&2; exit 1; }
  11364. fi
  11365. fi
  11366. HAVE_NLS=1
  11367. fi
  11368. # Enable C++ option
  11369. echo $ac_n "checking whether to use C++""... $ac_c" 1>&6
  11370. echo "configure:14194: checking whether to use C++" >&5
  11371. echo "$ac_t"""$with_cxx"" 1>&6
  11372. case "$with_cxx" in
  11373. "no") USE_CXX= ;;
  11374. "yes") USE_CXX="1" ;;
  11375. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  11376. esac
  11377. if test -n "$USE_CXX"; then
  11378. for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
  11379. do
  11380. # Extract the first word of "$ac_prog", so it can be a program name with args.
  11381. set dummy $ac_prog; ac_word=$2
  11382. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  11383. echo "configure:14210: checking for $ac_word" >&5
  11384. if test -n "$CXX"; then
  11385. ac_cv_prog_CXX="$CXX" # Let the user override the test.
  11386. else
  11387. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  11388. ac_dummy="$PATH"
  11389. for ac_dir in $ac_dummy; do
  11390. test -z "$ac_dir" && ac_dir=.
  11391. if test -f $ac_dir/$ac_word; then
  11392. ac_cv_prog_CXX="$ac_prog"
  11393. break
  11394. fi
  11395. done
  11396. IFS="$ac_save_ifs"
  11397. fi
  11398. CXX="$ac_cv_prog_CXX"
  11399. if test -n "$CXX"; then
  11400. echo "$ac_t""$CXX" 1>&6
  11401. else
  11402. echo "$ac_t""no" 1>&6
  11403. fi
  11404. test -n "$CXX" && break
  11405. done
  11406. test -n "$CXX" || CXX="gcc"
  11407. echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
  11408. echo "configure:14239: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
  11409. ac_ext=C
  11410. # CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  11411. ac_cpp='$CXXCPP $CPPFLAGS'
  11412. ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  11413. ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  11414. cross_compiling=$ac_cv_prog_cxx_cross
  11415. cat > conftest.$ac_ext << EOF
  11416. #line 14250 "configure"
  11417. #include "confdefs.h"
  11418. int main(){return(0);}
  11419. EOF
  11420. if { (eval echo configure:14255: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11421. ac_cv_prog_cxx_works=yes
  11422. # If we can't run a trivial program, we are probably using a cross compiler.
  11423. if (./conftest; exit) 2>/dev/null; then
  11424. ac_cv_prog_cxx_cross=no
  11425. else
  11426. ac_cv_prog_cxx_cross=yes
  11427. fi
  11428. else
  11429. echo "configure: failed program was:" >&5
  11430. cat conftest.$ac_ext >&5
  11431. ac_cv_prog_cxx_works=no
  11432. fi
  11433. rm -fr conftest*
  11434. ac_ext=c
  11435. # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
  11436. ac_cpp='$CPP $CPPFLAGS'
  11437. ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
  11438. ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
  11439. cross_compiling=$ac_cv_prog_cc_cross
  11440. echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
  11441. if test $ac_cv_prog_cxx_works = no; then
  11442. { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
  11443. fi
  11444. echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
  11445. echo "configure:14281: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
  11446. echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
  11447. cross_compiling=$ac_cv_prog_cxx_cross
  11448. echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
  11449. echo "configure:14286: checking whether we are using GNU C++" >&5
  11450. cat > conftest.C <<EOF
  11451. #ifdef __GNUC__
  11452. yes;
  11453. #endif
  11454. EOF
  11455. if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:14293: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
  11456. ac_cv_prog_gxx=yes
  11457. else
  11458. ac_cv_prog_gxx=no
  11459. fi
  11460. echo "$ac_t""$ac_cv_prog_gxx" 1>&6
  11461. if test $ac_cv_prog_gxx = yes; then
  11462. GXX=yes
  11463. else
  11464. GXX=
  11465. fi
  11466. ac_test_CXXFLAGS="${CXXFLAGS+set}"
  11467. ac_save_CXXFLAGS="$CXXFLAGS"
  11468. CXXFLAGS=
  11469. echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
  11470. echo "configure:14311: checking whether ${CXX-g++} accepts -g" >&5
  11471. echo 'void f(){}' > conftest.cc
  11472. if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
  11473. ac_cv_prog_cxx_g=yes
  11474. else
  11475. ac_cv_prog_cxx_g=no
  11476. fi
  11477. rm -f conftest*
  11478. echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
  11479. if test "$ac_test_CXXFLAGS" = set; then
  11480. CXXFLAGS="$ac_save_CXXFLAGS"
  11481. elif test $ac_cv_prog_cxx_g = yes; then
  11482. if test "$GXX" = yes; then
  11483. CXXFLAGS="-g -O2"
  11484. else
  11485. CXXFLAGS="-g"
  11486. fi
  11487. else
  11488. if test "$GXX" = yes; then
  11489. CXXFLAGS="-O2"
  11490. else
  11491. CXXFLAGS=
  11492. fi
  11493. fi
  11494. else
  11495. CXX=
  11496. CXXFLAGS=
  11497. fi
  11498. # Done checking C++
  11499. # Enable openDWG option
  11500. echo $ac_n "checking whether to use openDWG""... $ac_c" 1>&6
  11501. echo "configure:14352: checking whether to use openDWG" >&5
  11502. echo "$ac_t"""$with_opendwg"" 1>&6
  11503. case "$with_opendwg" in
  11504. "no") USE_OPENDWG= ;;
  11505. "yes") USE_OPENDWG="1" ;;
  11506. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  11507. esac
  11508. OPENDWGINCPATH=
  11509. OPENDWGLIBPATH=
  11510. OPENDWGLIB=
  11511. if test -n "${USE_OPENDWG}"; then
  11512. # With OPENDWG includes directory
  11513. echo $ac_n "checking for location of openDGW includes""... $ac_c" 1>&6
  11514. echo "configure:14372: checking for location of openDGW includes" >&5
  11515. case "$with_opendwg_includes" in
  11516. y | ye | yes | n | no)
  11517. { echo "configure: error: *** You must supply a directory to --with-opendwg-includes." 1>&2; exit 1; }
  11518. ;;
  11519. esac
  11520. echo "$ac_t""$with_opendwg_includes" 1>&6
  11521. if test -n "$with_opendwg_includes" ; then
  11522. for dir in $with_opendwg_includes; do
  11523. if test -d "$dir"; then
  11524. OPENDWGINCPATH="$OPENDWGINCPATH -I$dir"
  11525. else
  11526. { echo "configure: error: *** openDGW includes directory $dir does not exist." 1>&2; exit 1; }
  11527. fi
  11528. done
  11529. fi
  11530. ac_save_cppflags="$CPPFLAGS"
  11531. CPPFLAGS="$OPENDWGINCPATH $CPPFLAGS"
  11532. for ac_hdr in ad2.h
  11533. do
  11534. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  11535. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  11536. echo "configure:14398: checking for $ac_hdr" >&5
  11537. cat > conftest.$ac_ext <<EOF
  11538. #line 14401 "configure"
  11539. #include "confdefs.h"
  11540. #include <$ac_hdr>
  11541. EOF
  11542. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  11543. { (eval echo configure:14406: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  11544. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  11545. if test -z "$ac_err"; then
  11546. rm -rf conftest*
  11547. eval "ac_cv_header_$ac_safe=yes"
  11548. else
  11549. echo "$ac_err" >&5
  11550. echo "configure: failed program was:" >&5
  11551. cat conftest.$ac_ext >&5
  11552. rm -rf conftest*
  11553. eval "ac_cv_header_$ac_safe=no"
  11554. fi
  11555. rm -f conftest*
  11556. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  11557. echo "$ac_t""yes" 1>&6
  11558. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  11559. cat >> confdefs.h <<EOF
  11560. #define $ac_tr_hdr 1
  11561. EOF
  11562. else
  11563. echo "$ac_t""no" 1>&6
  11564. { echo "configure: error: *** Unable to locate openDWG includes." 1>&2; exit 1; }
  11565. fi
  11566. done
  11567. CPPFLAGS=$ac_save_cppflags
  11568. # With OPENDWG library directory
  11569. echo $ac_n "checking for location of openDWG library""... $ac_c" 1>&6
  11570. echo "configure:14440: checking for location of openDWG library" >&5
  11571. case "$with_opendwg_libs" in
  11572. y | ye | yes | n | no)
  11573. { echo "configure: error: *** You must supply a directory to --with-opendwg-libs." 1>&2; exit 1; }
  11574. ;;
  11575. esac
  11576. echo "$ac_t""$with_opendwg_libs" 1>&6
  11577. if test -n "$with_opendwg_libs"; then
  11578. for dir in $with_opendwg_libs; do
  11579. if test -d "$dir"; then
  11580. OPENDWGLIBPATH="$OPENDWGLIBPATH -L$dir"
  11581. else
  11582. { echo "configure: error: *** openDWG library directory $dir does not exist." 1>&2; exit 1; }
  11583. fi
  11584. done
  11585. fi
  11586. #search for ad2.a, ad3.a ... in openDWG toolkit directory:
  11587. #FIX ME how to program this test??
  11588. #LOC_CHECK_LIBS(ad?.a,adSeekLayer,openDWG,$OPENDWGLIBPATH,OPENDWGLIB,,)
  11589. #
  11590. #for now hack (but working):
  11591. TRUEOPENDWGLIBPATH=`echo $OPENDWGLIBPATH | cut -b3-`
  11592. adlib=`ls -1 $TRUEOPENDWGLIBPATH/ad?.a | tail -1`
  11593. OPENDWGLIB=$adlib
  11594. fi # $USE_OPENDWG
  11595. # Done checking OPENDWG
  11596. # Enable pthread option
  11597. echo $ac_n "checking whether to use POSIX threads""... $ac_c" 1>&6
  11598. echo "configure:14481: checking whether to use POSIX threads" >&5
  11599. echo "$ac_t"""$with_pthread"" 1>&6
  11600. case "$with_pthread" in
  11601. "no") USE_PTHREAD= ;;
  11602. "yes") USE_PTHREAD="1" ;;
  11603. *) { echo "configure: error: *** You must answer yes or no." 1>&2; exit 1; } ;;
  11604. esac
  11605. PTHREADINCPATH=
  11606. PTHREADLIBPATH=
  11607. PTHREADLIB=
  11608. if test -n "$USE_PTHREAD"; then
  11609. # With pthread includes directory
  11610. echo $ac_n "checking for location of POSIX threads includes""... $ac_c" 1>&6
  11611. echo "configure:14501: checking for location of POSIX threads includes" >&5
  11612. case "$with_pthread_includes" in
  11613. y | ye | yes | n | no)
  11614. { echo "configure: error: *** You must supply a directory to --with-pthread-includes." 1>&2; exit 1; }
  11615. ;;
  11616. esac
  11617. echo "$ac_t""$with_pthread_includes" 1>&6
  11618. if test -n "$with_pthread_includes" ; then
  11619. for dir in $with_pthread_includes; do
  11620. if test -d "$dir"; then
  11621. PTHREADINCPATH="$PTHREADINCPATH -I$dir"
  11622. else
  11623. { echo "configure: error: *** POSIX threads includes directory $dir does not exist." 1>&2; exit 1; }
  11624. fi
  11625. done
  11626. fi
  11627. ac_save_cppflags="$CPPFLAGS"
  11628. CPPFLAGS="$PTHREADINCPATH $CPPFLAGS"
  11629. for ac_hdr in pthread.h
  11630. do
  11631. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  11632. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  11633. echo "configure:14527: checking for $ac_hdr" >&5
  11634. cat > conftest.$ac_ext <<EOF
  11635. #line 14530 "configure"
  11636. #include "confdefs.h"
  11637. #include <$ac_hdr>
  11638. EOF
  11639. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  11640. { (eval echo configure:14535: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  11641. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  11642. if test -z "$ac_err"; then
  11643. rm -rf conftest*
  11644. eval "ac_cv_header_$ac_safe=yes"
  11645. else
  11646. echo "$ac_err" >&5
  11647. echo "configure: failed program was:" >&5
  11648. cat conftest.$ac_ext >&5
  11649. rm -rf conftest*
  11650. eval "ac_cv_header_$ac_safe=no"
  11651. fi
  11652. rm -f conftest*
  11653. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  11654. echo "$ac_t""yes" 1>&6
  11655. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  11656. cat >> confdefs.h <<EOF
  11657. #define $ac_tr_hdr 1
  11658. EOF
  11659. else
  11660. echo "$ac_t""no" 1>&6
  11661. { echo "configure: error: *** Unable to locate POSIX threads includes." 1>&2; exit 1; }
  11662. fi
  11663. done
  11664. CPPFLAGS=$ac_save_cppflags
  11665. # With pthread library directory
  11666. echo $ac_n "checking for location of POSIX threads library""... $ac_c" 1>&6
  11667. echo "configure:14569: checking for location of POSIX threads library" >&5
  11668. case "$with_pthread_libs" in
  11669. y | ye | yes | n | no)
  11670. { echo "configure: error: *** You must supply a directory to --with-pthread-libs." 1>&2; exit 1; }
  11671. ;;
  11672. esac
  11673. echo "$ac_t""$with_pthread_libs" 1>&6
  11674. if test -n "$with_pthread_libs"; then
  11675. for dir in $with_pthread_libs; do
  11676. if test -d "$dir"; then
  11677. PTHREADLIBPATH="$PTHREADLIBPATH -L$dir"
  11678. else
  11679. { echo "configure: error: *** POSIX threads library directory $dir does not exist." 1>&2; exit 1; }
  11680. fi
  11681. done
  11682. fi
  11683. ac_save_libs="$LIBS"
  11684. ac_save_ldflags="$LDFLAGS"
  11685. LIBS=" $LIBS"
  11686. LDFLAGS=" $LDFLAGS"
  11687. echo $ac_n "checking for pthread_create""... $ac_c" 1>&6
  11688. echo "configure:14594: checking for pthread_create" >&5
  11689. cat > conftest.$ac_ext <<EOF
  11690. #line 14597 "configure"
  11691. #include "confdefs.h"
  11692. /* System header to define __stub macros and hopefully few prototypes,
  11693. which can conflict with char pthread_create(); below. */
  11694. #include <assert.h>
  11695. /* Override any gcc2 internal prototype to avoid an error. */
  11696. /* We use char because int might match the return type of a gcc2
  11697. builtin and then its argument prototype would still apply. */
  11698. char pthread_create();
  11699. int main() {
  11700. /* The GNU C library defines this for functions which it implements
  11701. to always fail with ENOSYS. Some functions are actually named
  11702. something starting with __ and the normal name is an alias. */
  11703. #if defined (__stub_pthread_create) || defined (__stub___pthread_create)
  11704. choke me
  11705. #else
  11706. pthread_create();
  11707. #endif
  11708. ; return 0; }
  11709. EOF
  11710. if { (eval echo configure:14620: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11711. rm -rf conftest*
  11712. eval "ac_cv_func_pthread_create=yes"
  11713. else
  11714. echo "configure: failed program was:" >&5
  11715. cat conftest.$ac_ext >&5
  11716. rm -rf conftest*
  11717. eval "ac_cv_func_pthread_create=no"
  11718. fi
  11719. rm -f conftest*
  11720. if eval "test \"`echo '$ac_cv_func_'pthread_create`\" = yes"; then
  11721. echo "$ac_t""yes" 1>&6
  11722. PTHREADLIB="$PTHREADLIB "
  11723. else
  11724. echo "$ac_t""no" 1>&6
  11725. ac_save_ldflags="$LDFLAGS"
  11726. LDFLAGS="$PTHREADLIBPATH $LDFLAGS"
  11727. echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
  11728. echo "configure:14647: checking for pthread_create in -lpthread" >&5
  11729. ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
  11730. ac_save_LIBS="$LIBS"
  11731. LIBS="-lpthread $LIBS"
  11732. cat > conftest.$ac_ext <<EOF
  11733. #line 14653 "configure"
  11734. #include "confdefs.h"
  11735. /* Override any gcc2 internal prototype to avoid an error. */
  11736. /* We use char because int might match the return type of a gcc2
  11737. builtin and then its argument prototype would still apply. */
  11738. char pthread_create();
  11739. int main() {
  11740. pthread_create()
  11741. ; return 0; }
  11742. EOF
  11743. if { (eval echo configure:14664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
  11744. rm -rf conftest*
  11745. eval "ac_cv_lib_$ac_lib_var=yes"
  11746. else
  11747. echo "configure: failed program was:" >&5
  11748. cat conftest.$ac_ext >&5
  11749. rm -rf conftest*
  11750. eval "ac_cv_lib_$ac_lib_var=no"
  11751. fi
  11752. rm -f conftest*
  11753. LIBS="$ac_save_LIBS"
  11754. if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  11755. echo "$ac_t""yes" 1>&6
  11756. PTHREADLIB="$PTHREADLIB -lpthread "
  11757. else
  11758. echo "$ac_t""no" 1>&6
  11759. LDFLAGS=${ac_save_ldflags}
  11760. { echo "configure: error: *** Unable to locate POSIX threads library." 1>&2; exit 1; }
  11761. fi
  11762. LDFLAGS=${ac_save_ldflags}
  11763. fi
  11764. LIBS=${ac_save_libs}
  11765. LDFLAGS=${ac_save_ldflags}
  11766. fi # $USE_PTHREAD
  11767. # Done checking pthread
  11768. # Enable LFS (from cdr-tools)
  11769. # Check whether --enable-largefile or --disable-largefile was given.
  11770. if test "${enable_largefile+set}" = set; then
  11771. enableval="$enable_largefile"
  11772. :
  11773. fi
  11774. if test "$enable_largefile" = yes; then
  11775. echo $ac_n "checking for special C compiler options needed for large files""... $ac_c" 1>&6
  11776. echo "configure:14720: checking for special C compiler options needed for large files" >&5
  11777. ac_cv_sys_largefile_CC=no
  11778. largefile_cc_opt=""
  11779. if test "$GCC" != yes; then
  11780. # IRIX 6.2 and later do not support large files by default,
  11781. # so use the C compiler's -n32 option if that helps.
  11782. cat > conftest.$ac_ext <<EOF
  11783. #line 14728 "configure"
  11784. #include "confdefs.h"
  11785. #include <sys/types.h>
  11786. /* Check that off_t can represent 2**63 - 1 correctly.
  11787. We can't simply "#define LARGE_OFF_T 9223372036854775807",
  11788. since some C++ compilers masquerading as C compilers
  11789. incorrectly reject 9223372036854775807. */
  11790. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11791. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11792. && LARGE_OFF_T % 2147483647 == 1)
  11793. ? 1 : -1];
  11794. int main() {
  11795. ; return 0; }
  11796. EOF
  11797. if { (eval echo configure:14744: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11798. :
  11799. else
  11800. echo "configure: failed program was:" >&5
  11801. cat conftest.$ac_ext >&5
  11802. rm -rf conftest*
  11803. ac_save_CC="${CC-cc}"
  11804. CC="$CC -n32"
  11805. cat > conftest.$ac_ext <<EOF
  11806. #line 14753 "configure"
  11807. #include "confdefs.h"
  11808. #include <sys/types.h>
  11809. /* Check that off_t can represent 2**63 - 1 correctly.
  11810. We can't simply "#define LARGE_OFF_T 9223372036854775807",
  11811. since some C++ compilers masquerading as C compilers
  11812. incorrectly reject 9223372036854775807. */
  11813. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11814. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11815. && LARGE_OFF_T % 2147483647 == 1)
  11816. ? 1 : -1];
  11817. int main() {
  11818. ; return 0; }
  11819. EOF
  11820. if { (eval echo configure:14769: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11821. rm -rf conftest*
  11822. ac_cv_sys_largefile_CC=' -n32'
  11823. else
  11824. echo "configure: failed program was:" >&5
  11825. cat conftest.$ac_ext >&5
  11826. fi
  11827. rm -f conftest*
  11828. CC="$ac_save_CC"
  11829. fi
  11830. rm -f conftest*
  11831. fi
  11832. echo "$ac_t""$ac_cv_sys_largefile_CC" 1>&6
  11833. if test "$ac_cv_sys_largefile_CC" != no; then
  11834. CC="$CC$ac_cv_sys_largefile_CC"
  11835. largefile_cc_opt="$ac_cv_sys_largefile_CC"
  11836. fi
  11837. echo $ac_n "checking for _FILE_OFFSET_BITS value needed for large files""... $ac_c" 1>&6
  11838. echo "configure:14789: checking for _FILE_OFFSET_BITS value needed for large files" >&5
  11839. ac_cv_sys_file_offset_bits=no
  11840. cat > conftest.$ac_ext <<EOF
  11841. #line 14793 "configure"
  11842. #include "confdefs.h"
  11843. #include <sys/types.h>
  11844. /* Check that off_t can represent 2**63 - 1 correctly.
  11845. We can't simply "#define LARGE_OFF_T 9223372036854775807",
  11846. since some C++ compilers masquerading as C compilers
  11847. incorrectly reject 9223372036854775807. */
  11848. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11849. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11850. && LARGE_OFF_T % 2147483647 == 1)
  11851. ? 1 : -1];
  11852. int main() {
  11853. ; return 0; }
  11854. EOF
  11855. if { (eval echo configure:14809: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11856. :
  11857. else
  11858. echo "configure: failed program was:" >&5
  11859. cat conftest.$ac_ext >&5
  11860. rm -rf conftest*
  11861. cat > conftest.$ac_ext <<EOF
  11862. #line 14816 "configure"
  11863. #include "confdefs.h"
  11864. #define _FILE_OFFSET_BITS 64
  11865. #include <sys/types.h>
  11866. /* Check that off_t can represent 2**63 - 1 correctly.
  11867. We can't simply "#define LARGE_OFF_T 9223372036854775807",
  11868. since some C++ compilers masquerading as C compilers
  11869. incorrectly reject 9223372036854775807. */
  11870. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11871. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11872. && LARGE_OFF_T % 2147483647 == 1)
  11873. ? 1 : -1];
  11874. int main() {
  11875. ; return 0; }
  11876. EOF
  11877. if { (eval echo configure:14834: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11878. rm -rf conftest*
  11879. ac_cv_sys_file_offset_bits=64
  11880. else
  11881. echo "configure: failed program was:" >&5
  11882. cat conftest.$ac_ext >&5
  11883. fi
  11884. rm -f conftest*
  11885. fi
  11886. rm -f conftest*
  11887. echo "$ac_t""$ac_cv_sys_file_offset_bits" 1>&6
  11888. if test "$ac_cv_sys_file_offset_bits" != no; then
  11889. cat >> confdefs.h <<EOF
  11890. #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
  11891. EOF
  11892. fi
  11893. echo $ac_n "checking for _LARGE_FILES value needed for large files""... $ac_c" 1>&6
  11894. echo "configure:14853: checking for _LARGE_FILES value needed for large files" >&5
  11895. ac_cv_sys_large_files=no
  11896. cat > conftest.$ac_ext <<EOF
  11897. #line 14857 "configure"
  11898. #include "confdefs.h"
  11899. #include <sys/types.h>
  11900. /* Check that off_t can represent 2**63 - 1 correctly.
  11901. We can't simply "#define LARGE_OFF_T 9223372036854775807",
  11902. since some C++ compilers masquerading as C compilers
  11903. incorrectly reject 9223372036854775807. */
  11904. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11905. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11906. && LARGE_OFF_T % 2147483647 == 1)
  11907. ? 1 : -1];
  11908. int main() {
  11909. ; return 0; }
  11910. EOF
  11911. if { (eval echo configure:14873: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11912. :
  11913. else
  11914. echo "configure: failed program was:" >&5
  11915. cat conftest.$ac_ext >&5
  11916. rm -rf conftest*
  11917. cat > conftest.$ac_ext <<EOF
  11918. #line 14880 "configure"
  11919. #include "confdefs.h"
  11920. #define _LARGE_FILES 1
  11921. #include <sys/types.h>
  11922. /* Check that off_t can represent 2**63 - 1 correctly.
  11923. We can't simply "#define LARGE_OFF_T 9223372036854775807",
  11924. since some C++ compilers masquerading as C compilers
  11925. incorrectly reject 9223372036854775807. */
  11926. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  11927. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  11928. && LARGE_OFF_T % 2147483647 == 1)
  11929. ? 1 : -1];
  11930. int main() {
  11931. ; return 0; }
  11932. EOF
  11933. if { (eval echo configure:14898: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11934. rm -rf conftest*
  11935. ac_cv_sys_large_files=1
  11936. else
  11937. echo "configure: failed program was:" >&5
  11938. cat conftest.$ac_ext >&5
  11939. fi
  11940. rm -f conftest*
  11941. fi
  11942. rm -f conftest*
  11943. echo "$ac_t""$ac_cv_sys_large_files" 1>&6
  11944. if test "$ac_cv_sys_large_files" != no; then
  11945. cat >> confdefs.h <<EOF
  11946. #define _LARGE_FILES $ac_cv_sys_large_files
  11947. EOF
  11948. fi
  11949. echo $ac_n "checking for _LARGEFILE_SOURCE value needed for large files""... $ac_c" 1>&6
  11950. echo "configure:14917: checking for _LARGEFILE_SOURCE value needed for large files" >&5
  11951. ac_cv_sys_largefile_source=no
  11952. cat > conftest.$ac_ext <<EOF
  11953. #line 14921 "configure"
  11954. #include "confdefs.h"
  11955. #include <stdio.h>
  11956. int main() {
  11957. return !fseeko;
  11958. ; return 0; }
  11959. EOF
  11960. if { (eval echo configure:14928: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11961. :
  11962. else
  11963. echo "configure: failed program was:" >&5
  11964. cat conftest.$ac_ext >&5
  11965. rm -rf conftest*
  11966. cat > conftest.$ac_ext <<EOF
  11967. #line 14935 "configure"
  11968. #include "confdefs.h"
  11969. #define _LARGEFILE_SOURCE 1
  11970. #include <stdio.h>
  11971. int main() {
  11972. return !fseeko;
  11973. ; return 0; }
  11974. EOF
  11975. if { (eval echo configure:14944: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  11976. rm -rf conftest*
  11977. ac_cv_sys_largefile_source=1
  11978. else
  11979. echo "configure: failed program was:" >&5
  11980. cat conftest.$ac_ext >&5
  11981. fi
  11982. rm -f conftest*
  11983. fi
  11984. rm -f conftest*
  11985. echo "$ac_t""$ac_cv_sys_largefile_source" 1>&6
  11986. if test "$ac_cv_sys_largefile_source" != no; then
  11987. cat >> confdefs.h <<EOF
  11988. #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
  11989. EOF
  11990. fi
  11991. fi
  11992. echo $ac_n "checking if system supports Large Files at all""... $ac_c" 1>&6
  11993. echo "configure:14965: checking if system supports Large Files at all" >&5
  11994. cat > conftest.$ac_ext <<EOF
  11995. #line 14968 "configure"
  11996. #include "confdefs.h"
  11997. #include <stdio.h>
  11998. #include <sys/types.h>
  11999. int main() {
  12000. /*
  12001. * Check that off_t can represent 2**63 - 1 correctly.
  12002. * We can't simply "#define LARGE_OFF_T 9223372036854775807",
  12003. * since some C++ compilers masquerading as C compilers
  12004. * incorrectly reject 9223372036854775807.
  12005. *
  12006. * For MinGW, off64_t should be used and __MSVCRT_VERSION__ >= 0x0601
  12007. * (msvcrt.dll version 6.10 or higher) is needed for _fstat64 and _stat64.
  12008. */
  12009. #ifdef __MINGW32__
  12010. # define LARGE_OFF_T (((off64_t) 1 << 62) - 1 + ((off64_t) 1 << 62))
  12011. #else
  12012. # define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
  12013. #endif
  12014. int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
  12015. && LARGE_OFF_T % 2147483647 == 1)
  12016. ? 1 : -1];
  12017. #ifdef __MINGW32__
  12018. return !fseeko64;
  12019. return !ftello64;
  12020. #else
  12021. return !fseeko;
  12022. return !ftello;
  12023. #endif
  12024. ; return 0; }
  12025. EOF
  12026. if { (eval echo configure:15000: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
  12027. rm -rf conftest*
  12028. ac_cv_largefiles=yes
  12029. else
  12030. echo "configure: failed program was:" >&5
  12031. cat conftest.$ac_ext >&5
  12032. rm -rf conftest*
  12033. ac_cv_largefiles=no
  12034. fi
  12035. rm -f conftest*
  12036. echo "$ac_t""$ac_cv_largefiles" 1>&6
  12037. if test $ac_cv_largefiles = yes; then
  12038. cat >> confdefs.h <<\EOF
  12039. #define HAVE_LARGEFILES 1
  12040. EOF
  12041. fi
  12042. USE_LARGEFILES=
  12043. if test $ac_cv_largefiles = yes; then
  12044. USE_LARGEFILES=1
  12045. fi
  12046. # Done large file support
  12047. # Python check
  12048. echo $ac_n "checking whether to use Python""... $ac_c" 1>&6
  12049. echo "configure:15029: checking whether to use Python" >&5
  12050. PYTHONINC=
  12051. PYTHONCFLAGS=
  12052. PYTHONLDFLAGS=
  12053. SWIG=
  12054. USE_PYTHON=
  12055. if test "$with_python" = "no" ; then
  12056. echo "$ac_t""no" 1>&6
  12057. else
  12058. echo "$ac_t""yes" 1>&6
  12059. USE_PYTHON="1"
  12060. if test "$with_python" != "yes" ; then
  12061. PY_CONFIG="$with_python"
  12062. fi
  12063. # Extract the first word of "python-config", so it can be a program name with args.
  12064. set dummy python-config; ac_word=$2
  12065. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  12066. echo "configure:15049: checking for $ac_word" >&5
  12067. case "$PY_CONFIG" in
  12068. /*)
  12069. ac_cv_path_PY_CONFIG="$PY_CONFIG" # Let the user override the test with a path.
  12070. ;;
  12071. ?:/*)
  12072. ac_cv_path_PY_CONFIG="$PY_CONFIG" # Let the user override the test with a dos path.
  12073. ;;
  12074. *)
  12075. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  12076. ac_dummy="$PATH"
  12077. for ac_dir in $ac_dummy; do
  12078. test -z "$ac_dir" && ac_dir=.
  12079. if test -f $ac_dir/$ac_word; then
  12080. ac_cv_path_PY_CONFIG="$ac_dir/$ac_word"
  12081. break
  12082. fi
  12083. done
  12084. IFS="$ac_save_ifs"
  12085. test -z "$ac_cv_path_PY_CONFIG" && ac_cv_path_PY_CONFIG="no"
  12086. ;;
  12087. esac
  12088. PY_CONFIG="$ac_cv_path_PY_CONFIG"
  12089. if test -n "$PY_CONFIG"; then
  12090. echo "$ac_t""$PY_CONFIG" 1>&6
  12091. else
  12092. echo "$ac_t""no" 1>&6
  12093. fi
  12094. if test "$PY_CONFIG" != "no" ; then
  12095. # With Python includes directory
  12096. PYTHONINC=`"$PY_CONFIG" --includes`
  12097. ac_save_cppflags="$CPPFLAGS"
  12098. CPPFLAGS="$PYTHONINC $CPPFLAGS"
  12099. for ac_hdr in Python.h
  12100. do
  12101. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  12102. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  12103. echo "configure:15091: checking for $ac_hdr" >&5
  12104. cat > conftest.$ac_ext <<EOF
  12105. #line 15094 "configure"
  12106. #include "confdefs.h"
  12107. #include <$ac_hdr>
  12108. EOF
  12109. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  12110. { (eval echo configure:15099: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  12111. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  12112. if test -z "$ac_err"; then
  12113. rm -rf conftest*
  12114. eval "ac_cv_header_$ac_safe=yes"
  12115. else
  12116. echo "$ac_err" >&5
  12117. echo "configure: failed program was:" >&5
  12118. cat conftest.$ac_ext >&5
  12119. rm -rf conftest*
  12120. eval "ac_cv_header_$ac_safe=no"
  12121. fi
  12122. rm -f conftest*
  12123. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  12124. echo "$ac_t""yes" 1>&6
  12125. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  12126. cat >> confdefs.h <<EOF
  12127. #define $ac_tr_hdr 1
  12128. EOF
  12129. else
  12130. echo "$ac_t""no" 1>&6
  12131. { echo "configure: error: *** Unable to locate Python includes." 1>&2; exit 1; }
  12132. fi
  12133. done
  12134. CPPFLAGS=$ac_save_cppflags
  12135. PYTHONCFLAGS=`"$PY_CONFIG" --cflags`
  12136. # With Python library directory
  12137. PYTHONLDFLAGS=`"$PY_CONFIG" --ldflags`
  12138. fi
  12139. # look for the swig program
  12140. # Extract the first word of "swig", so it can be a program name with args.
  12141. set dummy swig; ac_word=$2
  12142. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  12143. echo "configure:15140: checking for $ac_word" >&5
  12144. case "$SWIG" in
  12145. /*)
  12146. ac_cv_path_SWIG="$SWIG" # Let the user override the test with a path.
  12147. ;;
  12148. ?:/*)
  12149. ac_cv_path_SWIG="$SWIG" # Let the user override the test with a dos path.
  12150. ;;
  12151. *)
  12152. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  12153. ac_dummy="$PATH"
  12154. for ac_dir in $ac_dummy; do
  12155. test -z "$ac_dir" && ac_dir=.
  12156. if test -f $ac_dir/$ac_word; then
  12157. ac_cv_path_SWIG="$ac_dir/$ac_word"
  12158. break
  12159. fi
  12160. done
  12161. IFS="$ac_save_ifs"
  12162. test -z "$ac_cv_path_SWIG" && ac_cv_path_SWIG="no"
  12163. ;;
  12164. esac
  12165. SWIG="$ac_cv_path_SWIG"
  12166. if test -n "$SWIG"; then
  12167. echo "$ac_t""$SWIG" 1>&6
  12168. else
  12169. echo "$ac_t""no" 1>&6
  12170. fi
  12171. if test "$SWIG" = "no" ; then
  12172. { echo "configure: error: *** couldn't find swig" 1>&2; exit 1; }
  12173. fi
  12174. fi # Done checking Python
  12175. # Enable wxWidgets support (for wxGUI)
  12176. echo $ac_n "checking whether to use wxWidgets""... $ac_c" 1>&6
  12177. echo "configure:15186: checking whether to use wxWidgets" >&5
  12178. WXVERSION=
  12179. WXWIDGETSCXXFLAGS=
  12180. WXWIDGETSCPPFLAGS=
  12181. WXWIDGETSLIB=
  12182. USE_WXWIDGETS=
  12183. if test "$with_wxwidgets" = "no" ; then
  12184. echo "$ac_t""no" 1>&6
  12185. else
  12186. echo "$ac_t""yes" 1>&6
  12187. USE_WXWIDGETS="1"
  12188. if test "$with_wxwidgets" != "yes" ; then
  12189. WX_CONFIG="$with_wxwidgets"
  12190. fi
  12191. # Extract the first word of "wx-config", so it can be a program name with args.
  12192. set dummy wx-config; ac_word=$2
  12193. echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
  12194. echo "configure:15206: checking for $ac_word" >&5
  12195. case "$WX_CONFIG" in
  12196. /*)
  12197. ac_cv_path_WX_CONFIG="$WX_CONFIG" # Let the user override the test with a path.
  12198. ;;
  12199. ?:/*)
  12200. ac_cv_path_WX_CONFIG="$WX_CONFIG" # Let the user override the test with a dos path.
  12201. ;;
  12202. *)
  12203. IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  12204. ac_dummy="$PATH"
  12205. for ac_dir in $ac_dummy; do
  12206. test -z "$ac_dir" && ac_dir=.
  12207. if test -f $ac_dir/$ac_word; then
  12208. ac_cv_path_WX_CONFIG="$ac_dir/$ac_word"
  12209. break
  12210. fi
  12211. done
  12212. IFS="$ac_save_ifs"
  12213. test -z "$ac_cv_path_WX_CONFIG" && ac_cv_path_WX_CONFIG="no"
  12214. ;;
  12215. esac
  12216. WX_CONFIG="$ac_cv_path_WX_CONFIG"
  12217. if test -n "$WX_CONFIG"; then
  12218. echo "$ac_t""$WX_CONFIG" 1>&6
  12219. else
  12220. echo "$ac_t""no" 1>&6
  12221. fi
  12222. if test "$WX_CONFIG" = "no" ; then
  12223. { echo "configure: error: *** couldn't find wx-config
  12224. wxWidgets must be installed on your system.
  12225. Please check that wx-config is in path, the directory
  12226. where wxWidgets libraries are installed (returned by
  12227. 'wx-config --libs' or 'wx-config --static --libs' command)
  12228. is in LD_LIBRARY_PATH or equivalent variable and
  12229. wxWidgets version is 2.8.1 or above." 1>&2; exit 1; }
  12230. fi
  12231. # Check wxWidgets version
  12232. REQWX="2.8.1"
  12233. echo $ac_n "checking wxWidgets version""... $ac_c" 1>&6
  12234. echo "configure:15254: checking wxWidgets version" >&5
  12235. if WXVERSION=`"$WX_CONFIG" --version`; then
  12236. echo "$ac_t""$WXVERSION" 1>&6
  12237. else
  12238. echo "$ac_t""not found" 1>&6
  12239. { echo "configure: error: wxWidgets is required." 1>&2; exit 1; }
  12240. fi
  12241. if test `expr "$WXVERSION" \< "$REQWX"` = 1 ; then
  12242. { echo "configure: error: *** wxWidgets "$REQWX" or later is required." 1>&2; exit 1; }
  12243. fi
  12244. # With wxWidgets includes directory
  12245. WXWIDGETSCXXFLAGS=`"$WX_CONFIG" --cxxflags`
  12246. WXWIDGETSCPPFLAGS=`"$WX_CONFIG" --cppflags`
  12247. ac_save_cppflags="$CPPFLAGS"
  12248. CPPFLAGS="$WXWIDGETSCPPFLAGS $CPPFLAGS"
  12249. for ac_hdr in wx/wxprec.h
  12250. do
  12251. ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
  12252. echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
  12253. echo "configure:15277: checking for $ac_hdr" >&5
  12254. cat > conftest.$ac_ext <<EOF
  12255. #line 15280 "configure"
  12256. #include "confdefs.h"
  12257. #include <$ac_hdr>
  12258. EOF
  12259. ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
  12260. { (eval echo configure:15285: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
  12261. ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
  12262. if test -z "$ac_err"; then
  12263. rm -rf conftest*
  12264. eval "ac_cv_header_$ac_safe=yes"
  12265. else
  12266. echo "$ac_err" >&5
  12267. echo "configure: failed program was:" >&5
  12268. cat conftest.$ac_ext >&5
  12269. rm -rf conftest*
  12270. eval "ac_cv_header_$ac_safe=no"
  12271. fi
  12272. rm -f conftest*
  12273. if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  12274. echo "$ac_t""yes" 1>&6
  12275. ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  12276. cat >> confdefs.h <<EOF
  12277. #define $ac_tr_hdr 1
  12278. EOF
  12279. else
  12280. echo "$ac_t""no" 1>&6
  12281. { echo "configure: error: *** Unable to locate wxWidgets includes." 1>&2; exit 1; }
  12282. fi
  12283. done
  12284. CPPFLAGS=$ac_save_cppflags
  12285. # With wxWidgets library directory
  12286. WXWIDGETSLIB=`"$WX_CONFIG" --libs`
  12287. fi # $USE_WXWIDGETS
  12288. # Done checking wxWidgets
  12289. USE_TERMIO=
  12290. STRIPFLAG=
  12291. GRASS_HOME=${DSTDIR}
  12292. trap '' 1 2 15
  12293. trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
  12294. test "x$prefix" = xNONE && prefix=$ac_default_prefix
  12295. # Let make expand exec_prefix.
  12296. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
  12297. # Any assignment to VPATH causes Sun make to only execute
  12298. # the first set of double-colon rules, so remove it if not needed.
  12299. # If there is a colon in the path, we need to keep it.
  12300. if test "x$srcdir" = x.; then
  12301. ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
  12302. fi
  12303. trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
  12304. DEFS=-DHAVE_CONFIG_H
  12305. # Without the "./", some shells look in PATH for config.status.
  12306. : ${CONFIG_STATUS=./config.status}
  12307. echo creating $CONFIG_STATUS
  12308. rm -f $CONFIG_STATUS
  12309. cat > $CONFIG_STATUS <<EOF
  12310. #! /bin/sh
  12311. # Generated automatically by configure.
  12312. # Run this file to recreate the current configuration.
  12313. # This directory was configured as follows,
  12314. # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  12315. #
  12316. # $0 $ac_configure_args
  12317. #
  12318. # Compiler output produced by configure, useful for debugging
  12319. # configure, is in ./config.log if it exists.
  12320. ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
  12321. for ac_option
  12322. do
  12323. case "\$ac_option" in
  12324. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
  12325. echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
  12326. exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  12327. -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
  12328. echo "$CONFIG_STATUS generated by autoconf version 2.13"
  12329. exit 0 ;;
  12330. -help | --help | --hel | --he | --h)
  12331. echo "\$ac_cs_usage"; exit 0 ;;
  12332. *) echo "\$ac_cs_usage"; exit 1 ;;
  12333. esac
  12334. done
  12335. ac_given_srcdir=$srcdir
  12336. ac_given_INSTALL="$INSTALL"
  12337. trap 'rm -fr `echo "include/Make/Platform.make include/version.h swig/perl/Makefile.PL swig/perl2/make.pl grass.pc include/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
  12338. EOF
  12339. cat >> $CONFIG_STATUS <<EOF
  12340. # Protect against being on the right side of a sed subst in config.status.
  12341. sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
  12342. s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
  12343. $ac_vpsub
  12344. $extrasub
  12345. s%@SHELL@%$SHELL%g
  12346. s%@CFLAGS@%$CFLAGS%g
  12347. s%@CPPFLAGS@%$CPPFLAGS%g
  12348. s%@CXXFLAGS@%$CXXFLAGS%g
  12349. s%@FFLAGS@%$FFLAGS%g
  12350. s%@DEFS@%$DEFS%g
  12351. s%@LDFLAGS@%$LDFLAGS%g
  12352. s%@LIBS@%$LIBS%g
  12353. s%@exec_prefix@%$exec_prefix%g
  12354. s%@prefix@%$prefix%g
  12355. s%@program_transform_name@%$program_transform_name%g
  12356. s%@bindir@%$bindir%g
  12357. s%@sbindir@%$sbindir%g
  12358. s%@libexecdir@%$libexecdir%g
  12359. s%@datadir@%$datadir%g
  12360. s%@sysconfdir@%$sysconfdir%g
  12361. s%@sharedstatedir@%$sharedstatedir%g
  12362. s%@localstatedir@%$localstatedir%g
  12363. s%@libdir@%$libdir%g
  12364. s%@includedir@%$includedir%g
  12365. s%@oldincludedir@%$oldincludedir%g
  12366. s%@infodir@%$infodir%g
  12367. s%@mandir@%$mandir%g
  12368. s%@host@%$host%g
  12369. s%@host_alias@%$host_alias%g
  12370. s%@host_cpu@%$host_cpu%g
  12371. s%@host_vendor@%$host_vendor%g
  12372. s%@host_os@%$host_os%g
  12373. s%@CC@%$CC%g
  12374. s%@EXEEXT@%$EXEEXT%g
  12375. s%@MINGW32@%$MINGW32%g
  12376. s%@BINDIR@%$BINDIR%g
  12377. s%@pwd@%$pwd%g
  12378. s%@SRCDIR@%$SRCDIR%g
  12379. s%@DSTDIR@%$DSTDIR%g
  12380. s%@ARCH@%$ARCH%g
  12381. s%@GISBASE@%$GISBASE%g
  12382. s%@GRASS_BIN@%$GRASS_BIN%g
  12383. s%@GRASS_VERSION_FILE@%$GRASS_VERSION_FILE%g
  12384. s%@GRASS_VERSION_MAJOR@%$GRASS_VERSION_MAJOR%g
  12385. s%@GRASS_VERSION_MINOR@%$GRASS_VERSION_MINOR%g
  12386. s%@GRASS_VERSION_RELEASE@%$GRASS_VERSION_RELEASE%g
  12387. s%@GRASS_VERSION_NUMBER@%$GRASS_VERSION_NUMBER%g
  12388. s%@GRASS_VERSION_DATE@%$GRASS_VERSION_DATE%g
  12389. s%@NAME_VER@%$NAME_VER%g
  12390. s%@LIB_VER@%$LIB_VER%g
  12391. s%@MACOSX_APP@%$MACOSX_APP%g
  12392. s%@INSTDIR@%$INSTDIR%g
  12393. s%@GRASS_LIB_PREFIX@%$GRASS_LIB_PREFIX%g
  12394. s%@GRASS_LIB_SUFFIX@%$GRASS_LIB_SUFFIX%g
  12395. s%@GRASS_LIBRARY_TYPE@%$GRASS_LIBRARY_TYPE%g
  12396. s%@RANLIB@%$RANLIB%g
  12397. s%@AR@%$AR%g
  12398. s%@CPP@%$CPP%g
  12399. s%@PLAT_OBJS@%$PLAT_OBJS%g
  12400. s%@CFLAGS_DEBUG@%$CFLAGS_DEBUG%g
  12401. s%@CFLAGS_OPTIMIZE@%$CFLAGS_OPTIMIZE%g
  12402. s%@CFLAGS_WARNING@%$CFLAGS_WARNING%g
  12403. s%@EXTRA_CFLAGS@%$EXTRA_CFLAGS%g
  12404. s%@LDFLAGS_DEBUG@%$LDFLAGS_DEBUG%g
  12405. s%@LDFLAGS_OPTIMIZE@%$LDFLAGS_OPTIMIZE%g
  12406. s%@CC_SEARCH_FLAGS@%$CC_SEARCH_FLAGS%g
  12407. s%@LD_SEARCH_FLAGS@%$LD_SEARCH_FLAGS%g
  12408. s%@LD_LIBRARY_PATH_VAR@%$LD_LIBRARY_PATH_VAR%g
  12409. s%@STLIB_LD@%$STLIB_LD%g
  12410. s%@SHLIB_LD@%$SHLIB_LD%g
  12411. s%@GRASS_SHLIB_LD_EXTRAS@%$GRASS_SHLIB_LD_EXTRAS%g
  12412. s%@SHLIB_LD_FLAGS@%$SHLIB_LD_FLAGS%g
  12413. s%@SHLIB_LD_LIBS@%$SHLIB_LD_LIBS%g
  12414. s%@SHLIB_CFLAGS@%$SHLIB_CFLAGS%g
  12415. s%@SHLIB_SUFFIX@%$SHLIB_SUFFIX%g
  12416. s%@MAKE_LIB@%$MAKE_LIB%g
  12417. s%@MAKE_STUB_LIB@%$MAKE_STUB_LIB%g
  12418. s%@INSTALL_LIB@%$INSTALL_LIB%g
  12419. s%@INSTALL_STUB_LIB@%$INSTALL_STUB_LIB%g
  12420. s%@INCLUDE_DIRS@%$INCLUDE_DIRS%g
  12421. s%@LIBRARY_DIRS@%$LIBRARY_DIRS%g
  12422. s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
  12423. s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
  12424. s%@INSTALL_DATA@%$INSTALL_DATA%g
  12425. s%@LEX@%$LEX%g
  12426. s%@LEXLIB@%$LEXLIB%g
  12427. s%@LEXPATH@%$LEXPATH%g
  12428. s%@YACC@%$YACC%g
  12429. s%@YACCPATH@%$YACCPATH%g
  12430. s%@ENV@%$ENV%g
  12431. s%@PERL@%$PERL%g
  12432. s%@CROSS_COMPILING@%$CROSS_COMPILING%g
  12433. s%@X_CFLAGS@%$X_CFLAGS%g
  12434. s%@X_LIBS@%$X_LIBS%g
  12435. s%@X_PRE_LIBS@%$X_PRE_LIBS%g
  12436. s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
  12437. s%@XLIB@%$XLIB%g
  12438. s%@XTLIB@%$XTLIB%g
  12439. s%@USE_X11@%$USE_X11%g
  12440. s%@DBMIEXTRALIB@%$DBMIEXTRALIB%g
  12441. s%@XDRLIB@%$XDRLIB%g
  12442. s%@HAVE_ASPRINTF@%$HAVE_ASPRINTF%g
  12443. s%@MATHLIB@%$MATHLIB%g
  12444. s%@DLLIB@%$DLLIB%g
  12445. s%@ICONVLIB@%$ICONVLIB%g
  12446. s%@SOCKLIB@%$SOCKLIB%g
  12447. s%@HAVE_SOCKET@%$HAVE_SOCKET%g
  12448. s%@ZLIBINCPATH@%$ZLIBINCPATH%g
  12449. s%@ZLIBLIBPATH@%$ZLIBLIBPATH%g
  12450. s%@ZLIB@%$ZLIB%g
  12451. s%@PROJINC@%$PROJINC%g
  12452. s%@PROJLIB@%$PROJLIB%g
  12453. s%@PROJSHARE@%$PROJSHARE%g
  12454. s%@NAD2BIN@%$NAD2BIN%g
  12455. s%@REGEXINCPATH@%$REGEXINCPATH%g
  12456. s%@REGEXLIBPATH@%$REGEXLIBPATH%g
  12457. s%@REGEXLIB@%$REGEXLIB%g
  12458. s%@USE_REGEX@%$USE_REGEX%g
  12459. s%@READLINEINCPATH@%$READLINEINCPATH%g
  12460. s%@READLINELIBPATH@%$READLINELIBPATH%g
  12461. s%@READLINELIB@%$READLINELIB%g
  12462. s%@HISTORYLIB@%$HISTORYLIB%g
  12463. s%@JPEGINCPATH@%$JPEGINCPATH%g
  12464. s%@JPEGLIBPATH@%$JPEGLIBPATH%g
  12465. s%@JPEGLIB@%$JPEGLIB%g
  12466. s%@GDAL_CONFIG@%$GDAL_CONFIG%g
  12467. s%@GDAL_LIBS@%$GDAL_LIBS%g
  12468. s%@GDAL_CFLAGS@%$GDAL_CFLAGS%g
  12469. s%@USE_GDAL@%$USE_GDAL%g
  12470. s%@USE_OGR@%$USE_OGR%g
  12471. s%@GEOS_CONFIG@%$GEOS_CONFIG%g
  12472. s%@GEOS_LIBS@%$GEOS_LIBS%g
  12473. s%@GEOS_CFLAGS@%$GEOS_CFLAGS%g
  12474. s%@USE_GEOS@%$USE_GEOS%g
  12475. s%@TIFF_INCLUDE_DIRS@%$TIFF_INCLUDE_DIRS%g
  12476. s%@TIFF_LIBRARY_DIRS@%$TIFF_LIBRARY_DIRS%g
  12477. s%@TIFFLIB@%$TIFFLIB%g
  12478. s%@PNGINC@%$PNGINC%g
  12479. s%@PNGLIB@%$PNGLIB%g
  12480. s%@USE_PNG@%$USE_PNG%g
  12481. s%@USE_POSTGRES@%$USE_POSTGRES%g
  12482. s%@PQINCPATH@%$PQINCPATH%g
  12483. s%@PQLIBPATH@%$PQLIBPATH%g
  12484. s%@PQLIB@%$PQLIB%g
  12485. s%@MYSQLD_CONFIG@%$MYSQLD_CONFIG%g
  12486. s%@USE_MYSQL@%$USE_MYSQL%g
  12487. s%@MYSQLINCPATH@%$MYSQLINCPATH%g
  12488. s%@MYSQLLIBPATH@%$MYSQLLIBPATH%g
  12489. s%@MYSQLLIB@%$MYSQLLIB%g
  12490. s%@MYSQLDLIB@%$MYSQLDLIB%g
  12491. s%@USE_SQLITE@%$USE_SQLITE%g
  12492. s%@SQLITEINCPATH@%$SQLITEINCPATH%g
  12493. s%@SQLITELIBPATH@%$SQLITELIBPATH%g
  12494. s%@SQLITELIB@%$SQLITELIB%g
  12495. s%@USE_FFMPEG@%$USE_FFMPEG%g
  12496. s%@FFMPEGINCPATH@%$FFMPEGINCPATH%g
  12497. s%@FFMPEGLIBPATH@%$FFMPEGLIBPATH%g
  12498. s%@FFMPEGLIB@%$FFMPEGLIB%g
  12499. s%@USE_OPENGL@%$USE_OPENGL%g
  12500. s%@OPENGL_X11@%$OPENGL_X11%g
  12501. s%@OPENGL_AQUA@%$OPENGL_AQUA%g
  12502. s%@OPENGL_WINDOWS@%$OPENGL_WINDOWS%g
  12503. s%@OPENGLINC@%$OPENGLINC%g
  12504. s%@OPENGLLIB@%$OPENGLLIB%g
  12505. s%@OPENGLULIB@%$OPENGLULIB%g
  12506. s%@TCLINCDIR@%$TCLINCDIR%g
  12507. s%@TKINCDIR@%$TKINCDIR%g
  12508. s%@TCLTKLIBPATH@%$TCLTKLIBPATH%g
  12509. s%@TCLTKLIBS@%$TCLTKLIBS%g
  12510. s%@TCLTKAQUA_IS64BIT@%$TCLTKAQUA_IS64BIT%g
  12511. s%@ODBCINC@%$ODBCINC%g
  12512. s%@ODBCLIB@%$ODBCLIB%g
  12513. s%@FFTWINC@%$FFTWINC%g
  12514. s%@FFTWLIB@%$FFTWLIB%g
  12515. s%@BLASLIB@%$BLASLIB%g
  12516. s%@BLASINC@%$BLASINC%g
  12517. s%@LAPACKLIB@%$LAPACKLIB%g
  12518. s%@LAPACKINC@%$LAPACKINC%g
  12519. s%@CAIRO_HAS_XRENDER@%$CAIRO_HAS_XRENDER%g
  12520. s%@CAIRO_HAS_XRENDER_SURFACE@%$CAIRO_HAS_XRENDER_SURFACE%g
  12521. s%@CAIROINC@%$CAIROINC%g
  12522. s%@CAIROLIB@%$CAIROLIB%g
  12523. s%@USE_CAIRO@%$USE_CAIRO%g
  12524. s%@FTINC@%$FTINC%g
  12525. s%@FTLIB@%$FTLIB%g
  12526. s%@INTLLIB@%$INTLLIB%g
  12527. s%@HAVE_NLS@%$HAVE_NLS%g
  12528. s%@CXX@%$CXX%g
  12529. s%@OPENDWGINCPATH@%$OPENDWGINCPATH%g
  12530. s%@OPENDWGLIBPATH@%$OPENDWGLIBPATH%g
  12531. s%@OPENDWGLIB@%$OPENDWGLIB%g
  12532. s%@USE_OPENDWG@%$USE_OPENDWG%g
  12533. s%@PTHREADINCPATH@%$PTHREADINCPATH%g
  12534. s%@PTHREADLIBPATH@%$PTHREADLIBPATH%g
  12535. s%@PTHREADLIB@%$PTHREADLIB%g
  12536. s%@USE_PTHREAD@%$USE_PTHREAD%g
  12537. s%@USE_LARGEFILES@%$USE_LARGEFILES%g
  12538. s%@PY_CONFIG@%$PY_CONFIG%g
  12539. s%@SWIG@%$SWIG%g
  12540. s%@PYTHONINC@%$PYTHONINC%g
  12541. s%@PYTHONCFLAGS@%$PYTHONCFLAGS%g
  12542. s%@PYTHONLDFLAGS@%$PYTHONLDFLAGS%g
  12543. s%@USE_PYTHON@%$USE_PYTHON%g
  12544. s%@WX_CONFIG@%$WX_CONFIG%g
  12545. s%@WXVERSION@%$WXVERSION%g
  12546. s%@WXWIDGETSCXXFLAGS@%$WXWIDGETSCXXFLAGS%g
  12547. s%@WXWIDGETSCPPFLAGS@%$WXWIDGETSCPPFLAGS%g
  12548. s%@WXWIDGETSLIB@%$WXWIDGETSLIB%g
  12549. s%@USE_WXWIDGETS@%$USE_WXWIDGETS%g
  12550. s%@USE_TERMIO@%$USE_TERMIO%g
  12551. s%@STRIPFLAG@%$STRIPFLAG%g
  12552. s%@GRASS_HOME@%$GRASS_HOME%g
  12553. CEOF
  12554. EOF
  12555. cat >> $CONFIG_STATUS <<\EOF
  12556. # Split the substitutions into bite-sized pieces for seds with
  12557. # small command number limits, like on Digital OSF/1 and HP-UX.
  12558. ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
  12559. ac_file=1 # Number of current file.
  12560. ac_beg=1 # First line for current file.
  12561. ac_end=$ac_max_sed_cmds # Line after last line for current file.
  12562. ac_more_lines=:
  12563. ac_sed_cmds=""
  12564. while $ac_more_lines; do
  12565. if test $ac_beg -gt 1; then
  12566. sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
  12567. else
  12568. sed "${ac_end}q" conftest.subs > conftest.s$ac_file
  12569. fi
  12570. if test ! -s conftest.s$ac_file; then
  12571. ac_more_lines=false
  12572. rm -f conftest.s$ac_file
  12573. else
  12574. if test -z "$ac_sed_cmds"; then
  12575. ac_sed_cmds="sed -f conftest.s$ac_file"
  12576. else
  12577. ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
  12578. fi
  12579. ac_file=`expr $ac_file + 1`
  12580. ac_beg=$ac_end
  12581. ac_end=`expr $ac_end + $ac_max_sed_cmds`
  12582. fi
  12583. done
  12584. if test -z "$ac_sed_cmds"; then
  12585. ac_sed_cmds=cat
  12586. fi
  12587. EOF
  12588. cat >> $CONFIG_STATUS <<EOF
  12589. CONFIG_FILES=\${CONFIG_FILES-"include/Make/Platform.make include/version.h swig/perl/Makefile.PL swig/perl2/make.pl grass.pc"}
  12590. EOF
  12591. cat >> $CONFIG_STATUS <<\EOF
  12592. for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  12593. # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
  12594. case "$ac_file" in
  12595. *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
  12596. ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  12597. *) ac_file_in="${ac_file}.in" ;;
  12598. esac
  12599. # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
  12600. # Remove last slash and all that follows it. Not all systems have dirname.
  12601. ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  12602. if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  12603. # The file is in a subdirectory.
  12604. test ! -d "$ac_dir" && mkdir "$ac_dir"
  12605. ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
  12606. # A "../" for each directory in $ac_dir_suffix.
  12607. ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  12608. else
  12609. ac_dir_suffix= ac_dots=
  12610. fi
  12611. case "$ac_given_srcdir" in
  12612. .) srcdir=.
  12613. if test -z "$ac_dots"; then top_srcdir=.
  12614. else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  12615. /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
  12616. *) # Relative path.
  12617. srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
  12618. top_srcdir="$ac_dots$ac_given_srcdir" ;;
  12619. esac
  12620. case "$ac_given_INSTALL" in
  12621. [/$]*) INSTALL="$ac_given_INSTALL" ;;
  12622. *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
  12623. esac
  12624. echo creating "$ac_file"
  12625. rm -f "$ac_file"
  12626. configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
  12627. case "$ac_file" in
  12628. *Makefile*) ac_comsub="1i\\
  12629. # $configure_input" ;;
  12630. *) ac_comsub= ;;
  12631. esac
  12632. ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
  12633. sed -e "$ac_comsub
  12634. s%@configure_input@%$configure_input%g
  12635. s%@srcdir@%$srcdir%g
  12636. s%@top_srcdir@%$top_srcdir%g
  12637. s%@INSTALL@%$INSTALL%g
  12638. " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
  12639. fi; done
  12640. rm -f conftest.s*
  12641. # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
  12642. # NAME is the cpp macro being defined and VALUE is the value it is being given.
  12643. #
  12644. # ac_d sets the value in "#define NAME VALUE" lines.
  12645. ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
  12646. ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
  12647. ac_dC='\3'
  12648. ac_dD='%g'
  12649. # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
  12650. ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
  12651. ac_uB='\([ ]\)%\1#\2define\3'
  12652. ac_uC=' '
  12653. ac_uD='\4%g'
  12654. # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
  12655. ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
  12656. ac_eB='$%\1#\2define\3'
  12657. ac_eC=' '
  12658. ac_eD='%g'
  12659. if test "${CONFIG_HEADERS+set}" != set; then
  12660. EOF
  12661. cat >> $CONFIG_STATUS <<EOF
  12662. CONFIG_HEADERS="include/config.h"
  12663. EOF
  12664. cat >> $CONFIG_STATUS <<\EOF
  12665. fi
  12666. for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
  12667. # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
  12668. case "$ac_file" in
  12669. *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
  12670. ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  12671. *) ac_file_in="${ac_file}.in" ;;
  12672. esac
  12673. echo creating $ac_file
  12674. rm -f conftest.frag conftest.in conftest.out
  12675. ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
  12676. cat $ac_file_inputs > conftest.in
  12677. EOF
  12678. # Transform confdefs.h into a sed script conftest.vals that substitutes
  12679. # the proper values into config.h.in to produce config.h. And first:
  12680. # Protect against being on the right side of a sed subst in config.status.
  12681. # Protect against being in an unquoted here document in config.status.
  12682. rm -f conftest.vals
  12683. cat > conftest.hdr <<\EOF
  12684. s/[\\&%]/\\&/g
  12685. s%[\\$`]%\\&%g
  12686. s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
  12687. s%ac_d%ac_u%gp
  12688. s%ac_u%ac_e%gp
  12689. EOF
  12690. sed -n -f conftest.hdr confdefs.h > conftest.vals
  12691. rm -f conftest.hdr
  12692. # This sed command replaces #undef with comments. This is necessary, for
  12693. # example, in the case of _POSIX_SOURCE, which is predefined and required
  12694. # on some systems where configure will not decide to define it.
  12695. cat >> conftest.vals <<\EOF
  12696. s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
  12697. EOF
  12698. # Break up conftest.vals because some shells have a limit on
  12699. # the size of here documents, and old seds have small limits too.
  12700. rm -f conftest.tail
  12701. while :
  12702. do
  12703. ac_lines=`grep -c . conftest.vals`
  12704. # grep -c gives empty output for an empty file on some AIX systems.
  12705. if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  12706. # Write a limited-size here document to conftest.frag.
  12707. echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
  12708. sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
  12709. echo 'CEOF
  12710. sed -f conftest.frag conftest.in > conftest.out
  12711. rm -f conftest.in
  12712. mv conftest.out conftest.in
  12713. ' >> $CONFIG_STATUS
  12714. sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
  12715. rm -f conftest.vals
  12716. mv conftest.tail conftest.vals
  12717. done
  12718. rm -f conftest.vals
  12719. cat >> $CONFIG_STATUS <<\EOF
  12720. rm -f conftest.frag conftest.h
  12721. echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
  12722. cat conftest.in >> conftest.h
  12723. rm -f conftest.in
  12724. if cmp -s $ac_file conftest.h 2>/dev/null; then
  12725. echo "$ac_file is unchanged"
  12726. rm -f conftest.h
  12727. else
  12728. # Remove last slash and all that follows it. Not all systems have dirname.
  12729. ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  12730. if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
  12731. # The file is in a subdirectory.
  12732. test ! -d "$ac_dir" && mkdir "$ac_dir"
  12733. fi
  12734. rm -f $ac_file
  12735. mv conftest.h $ac_file
  12736. fi
  12737. fi; done
  12738. EOF
  12739. cat >> $CONFIG_STATUS <<EOF
  12740. EOF
  12741. cat >> $CONFIG_STATUS <<\EOF
  12742. exit 0
  12743. EOF
  12744. chmod +x $CONFIG_STATUS
  12745. rm -fr confdefs* $ac_clean_files
  12746. test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
  12747. echo "Copying config.status to config.status.${ARCH}"
  12748. cp -f config.status config.status.${ARCH}
  12749. # Display configuration status
  12750. USE_TOGL=
  12751. if test -n "${USE_TCLTK}" -a -n "${USE_OPENGL}" ; then
  12752. USE_TOGL="1"
  12753. fi
  12754. echo ""
  12755. echo "GRASS is now configured for: ${host}"
  12756. echo ""
  12757. echo " Source directory: ${SRCDIR}"
  12758. echo " Build directory: ${DSTDIR}"
  12759. echo " Installation directory: ${INSTDIR}"
  12760. echo " Startup script in directory: ${bindir}"
  12761. echo " C compiler: ${CC} ${CFLAGS}"
  12762. echo " C++ compiler: ${CXX} ${CXXFLAGS}"
  12763. #LOC_MSG([ FORTRAN compiler: ${F77} ${FFLAGS}])
  12764. echo " Building shared libraries: ${shared_ok}"
  12765. echo " 64bit support: ${do64bit}"
  12766. echo " OpenGL platform: ${OPENGL_TYPE}"
  12767. echo ""
  12768. echo " MacOSX application: `if test -n "${MACOSX_APP}" ; then echo yes ; else echo no ; fi`"
  12769. echo ""
  12770. echo " NVIZ: `if test -n "${USE_TOGL}" ; then echo yes ; else echo no ; fi`"
  12771. echo ""
  12772. echo " BLAS support: `if test -n "${USE_BLAS}" ; then echo yes ; else echo no ; fi`"
  12773. echo " C++ support: `if test -n "${USE_CXX}" ; then echo yes ; else echo no ; fi`"
  12774. echo " Cairo support: `if test -n "${USE_CAIRO}" ; then echo yes ; else echo no ; fi`"
  12775. echo " DWG support: `if test -n "${USE_OPENDWG}" ; then echo yes ; else echo no ; fi`"
  12776. echo " FFMPEG support: `if test -n "${USE_FFMPEG}" ; then echo yes ; else echo no ; fi`"
  12777. echo " FFTW support: `if test -n "${USE_FFTW}" ; then echo yes ; else echo no ; fi`"
  12778. echo " FreeType support: `if test -n "${USE_FREETYPE}" ; then echo yes ; else echo no ; fi`"
  12779. echo " GDAL support: `if test -n "${USE_GDAL}" ; then echo yes ; else echo no ; fi`"
  12780. echo " GEOS support: `if test -n "${USE_GEOS}" ; then echo yes ; else echo no ; fi`"
  12781. echo " JPEG support: `if test -n "${USE_JPEG}" ; then echo yes ; else echo no ; fi`"
  12782. echo " LAPACK support: `if test -n "${USE_LAPACK}" ; then echo yes ; else echo no ; fi`"
  12783. echo " Large File support (LFS): `if test -n "${USE_LARGEFILES}" ; then echo yes ; else echo no ; fi`"
  12784. echo " MySQL support: `if test -n "${USE_MYSQL}" ; then echo yes ; else echo no ; fi`"
  12785. echo " NLS support: `if test -n "${USE_NLS}" ; then echo yes ; else echo no ; fi`"
  12786. echo " ODBC support: `if test -n "${USE_ODBC}" ; then echo yes ; else echo no ; fi`"
  12787. echo " OGR support: `if test -n "${USE_OGR}" ; then echo yes ; else echo no ; fi`"
  12788. echo " OpenGL support: `if test -n "${USE_OPENGL}" ; then echo yes ; else echo no ; fi`"
  12789. echo " PNG support: `if test -n "${USE_PNG}" ; then echo yes ; else echo no ; fi`"
  12790. echo " PostgreSQL support: `if test -n "${USE_POSTGRES}" ; then echo yes ; else echo no ; fi`"
  12791. echo " Python support: `if test -n "${USE_PYTHON}" ; then echo yes ; else echo no ; fi`"
  12792. echo " Readline support: `if test -n "${USE_READLINE}" ; then echo yes ; else echo no ; fi`"
  12793. echo " SQLite support: `if test -n "${USE_SQLITE}" ; then echo yes ; else echo no ; fi`"
  12794. echo " Tcl/Tk support: `if test -n "${USE_TCLTK}" ; then echo yes ; else echo no ; fi`"
  12795. echo " wxWidgets support: `if test -n "${USE_WXWIDGETS}" ; then echo yes ; else echo no ; fi`"
  12796. echo " TIFF support: `if test -n "${USE_TIFF}" ; then echo yes ; else echo no ; fi`"
  12797. echo " X11 support: `if test -n "${USE_X11}" ; then echo yes ; else echo no ; fi`"
  12798. echo " Regex support: `if test -n "${USE_REGEX}" ; then echo yes ; else echo no ; fi`"
  12799. echo " POSIX thread support: `if test -n "${USE_PTHREAD}" ; then echo yes ; else echo no ; fi`"
  12800. echo ""