patch-aclocal_m4 164 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831
  1. --- Libnet-1.0.2a.orig/aclocal.m4 2001-01-07 21:49:29.000000000 +0100
  2. +++ Libnet-1.0.2a/aclocal.m4 2009-06-12 21:48:27.000000000 +0200
  3. @@ -1,358 +1,4525 @@
  4. -dnl aclocal.m4 generated automatically by aclocal 1.4
  5. +# generated automatically by aclocal 1.8.5 -*- Autoconf -*-
  6. -dnl Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
  7. -dnl This file is free software; the Free Software Foundation
  8. -dnl gives unlimited permission to copy and/or distribute it,
  9. -dnl with or without modifications, as long as this notice is preserved.
  10. +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
  11. +# Free Software Foundation, Inc.
  12. +# This file is free software; the Free Software Foundation
  13. +# gives unlimited permission to copy and/or distribute it,
  14. +# with or without modifications, as long as this notice is preserved.
  15. -dnl This program is distributed in the hope that it will be useful,
  16. -dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  17. -dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  18. -dnl PARTICULAR PURPOSE.
  19. +# This program is distributed in the hope that it will be useful,
  20. +# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
  21. +# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  22. +# PARTICULAR PURPOSE.
  23. -dnl $Id: aclocal.m4,v 1.1.1.1 2000/05/25 00:28:49 route Exp $
  24. -dnl
  25. -dnl Libnet specific autoconf macros
  26. -dnl Copyright (c) 1998, 1999, 2000 Mike D. Schiffman <mike@infonexus.com>
  27. -dnl All rights reserved.
  28. -dnl
  29. +# libtool.m4 - Configure libtool for the host system. -*-Shell-script-*-
  30. -dnl
  31. -dnl Checks to see if this linux kernel has a working PF_PACKET
  32. -dnl
  33. -dnl usage:
  34. -dnl
  35. -dnl AC_LIBNET_CHECK_PF_PACKET
  36. -dnl
  37. -dnl results:
  38. -dnl
  39. -dnl HAVE_PF_PACKET (DEFINED)
  40. +# serial 46 AC_PROG_LIBTOOL
  41. +# Debian $Rev: 102 $
  42. +
  43. +AC_DEFUN([AC_PROG_LIBTOOL],
  44. +[AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
  45. +
  46. +# This can be used to rebuild libtool when needed
  47. +LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
  48. +
  49. +# Always use our own libtool.
  50. +LIBTOOL='$(SHELL) $(top_builddir)/libtool'
  51. +AC_SUBST(LIBTOOL)dnl
  52. +
  53. +# Prevent multiple expansion
  54. +define([AC_PROG_LIBTOOL], [])
  55. +])
  56. +
  57. +AC_DEFUN([AC_LIBTOOL_SETUP],
  58. +[AC_PREREQ(2.13)dnl
  59. +AC_REQUIRE([AC_ENABLE_SHARED])dnl
  60. +AC_REQUIRE([AC_ENABLE_STATIC])dnl
  61. +AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl
  62. +AC_REQUIRE([AC_CANONICAL_HOST])dnl
  63. +AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  64. +AC_REQUIRE([AC_PROG_CC])dnl
  65. +AC_REQUIRE([AC_PROG_LD])dnl
  66. +AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl
  67. +AC_REQUIRE([AC_PROG_NM])dnl
  68. +AC_REQUIRE([LT_AC_PROG_SED])dnl
  69. +
  70. +AC_REQUIRE([AC_PROG_LN_S])dnl
  71. +AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
  72. +AC_REQUIRE([AC_OBJEXT])dnl
  73. +AC_REQUIRE([AC_EXEEXT])dnl
  74. dnl
  75. -AC_DEFUN(AC_LIBNET_CHECK_PF_PACKET,
  76. -[
  77. - AC_MSG_CHECKING(for PF_PACKET)
  78. - AC_CACHE_VAL(ac_libnet_have_pf_packet,
  79. +_LT_AC_PROG_ECHO_BACKSLASH
  80. +# Only perform the check for file, if the check method requires it
  81. +case $deplibs_check_method in
  82. +file_magic*)
  83. + if test "$file_magic_cmd" = '$MAGIC_CMD'; then
  84. + AC_PATH_MAGIC
  85. + fi
  86. + ;;
  87. +esac
  88. - [case "$target_os" in
  89. +AC_CHECK_TOOL(RANLIB, ranlib, :)
  90. +AC_CHECK_TOOL(STRIP, strip, :)
  91. - linux)
  92. - ac_libnet_have_pf_packet = no
  93. - ;;
  94. - *)
  95. +ifdef([AC_PROVIDE_AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
  96. +ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL],
  97. +enable_win32_dll=yes, enable_win32_dll=no)
  98. - cat > pf_packet-test.c << EOF
  99. -#include <net/if.h>
  100. -#if (__GLIBC__)
  101. -#include <netinet/if_ether.h>
  102. -#include <net/if_arp.h>
  103. +AC_ARG_ENABLE(libtool-lock,
  104. + [ --disable-libtool-lock avoid locking (might break parallel builds)])
  105. +test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
  106. +
  107. +# Some flags need to be propagated to the compiler or linker for good
  108. +# libtool support.
  109. +case $host in
  110. +*-*-irix6*)
  111. + # Find out which ABI we are using.
  112. + echo '[#]line __oline__ "configure"' > conftest.$ac_ext
  113. + if AC_TRY_EVAL(ac_compile); then
  114. + case `/usr/bin/file conftest.$ac_objext` in
  115. + *32-bit*)
  116. + LD="${LD-ld} -32"
  117. + ;;
  118. + *N32*)
  119. + LD="${LD-ld} -n32"
  120. + ;;
  121. + *64-bit*)
  122. + LD="${LD-ld} -64"
  123. + ;;
  124. + esac
  125. + fi
  126. + rm -rf conftest*
  127. + ;;
  128. +
  129. +*-*-sco3.2v5*)
  130. + # On SCO OpenServer 5, we need -belf to get full-featured binaries.
  131. + SAVE_CFLAGS="$CFLAGS"
  132. + CFLAGS="$CFLAGS -belf"
  133. + AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf,
  134. + [AC_LANG_SAVE
  135. + AC_LANG_C
  136. + AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no])
  137. + AC_LANG_RESTORE])
  138. + if test x"$lt_cv_cc_needs_belf" != x"yes"; then
  139. + # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
  140. + CFLAGS="$SAVE_CFLAGS"
  141. + fi
  142. + ;;
  143. +
  144. +ifdef([AC_PROVIDE_AC_LIBTOOL_WIN32_DLL],
  145. +[*-*-cygwin* | *-*-mingw* | *-*-pw32*)
  146. + AC_CHECK_TOOL(DLLTOOL, dlltool, false)
  147. + AC_CHECK_TOOL(AS, as, false)
  148. + AC_CHECK_TOOL(OBJDUMP, objdump, false)
  149. +
  150. + # recent cygwin and mingw systems supply a stub DllMain which the user
  151. + # can override, but on older systems we have to supply one
  152. + AC_CACHE_CHECK([if libtool should supply DllMain function], lt_cv_need_dllmain,
  153. + [AC_TRY_LINK([],
  154. + [extern int __attribute__((__stdcall__)) DllMain(void*, int, void*);
  155. + DllMain (0, 0, 0);],
  156. + [lt_cv_need_dllmain=no],[lt_cv_need_dllmain=yes])])
  157. +
  158. + case $host/$CC in
  159. + *-*-cygwin*/gcc*-mno-cygwin*|*-*-mingw*)
  160. + # old mingw systems require "-dll" to link a DLL, while more recent ones
  161. + # require "-mdll"
  162. + SAVE_CFLAGS="$CFLAGS"
  163. + CFLAGS="$CFLAGS -mdll"
  164. + AC_CACHE_CHECK([how to link DLLs], lt_cv_cc_dll_switch,
  165. + [AC_TRY_LINK([], [], [lt_cv_cc_dll_switch=-mdll],[lt_cv_cc_dll_switch=-dll])])
  166. + CFLAGS="$SAVE_CFLAGS" ;;
  167. + *-*-cygwin* | *-*-pw32*)
  168. + # cygwin systems need to pass --dll to the linker, and not link
  169. + # crt.o which will require a WinMain@16 definition.
  170. + lt_cv_cc_dll_switch="-Wl,--dll -nostartfiles" ;;
  171. + esac
  172. + ;;
  173. + ])
  174. +esac
  175. +
  176. +_LT_AC_LTCONFIG_HACK
  177. +
  178. +])
  179. +
  180. +# AC_LIBTOOL_HEADER_ASSERT
  181. +# ------------------------
  182. +AC_DEFUN([AC_LIBTOOL_HEADER_ASSERT],
  183. +[AC_CACHE_CHECK([whether $CC supports assert without backlinking],
  184. + [lt_cv_func_assert_works],
  185. + [case $host in
  186. + *-*-solaris*)
  187. + if test "$GCC" = yes && test "$with_gnu_ld" != yes; then
  188. + case `$CC --version 2>/dev/null` in
  189. + [[12]].*) lt_cv_func_assert_works=no ;;
  190. + *) lt_cv_func_assert_works=yes ;;
  191. + esac
  192. + fi
  193. + ;;
  194. + esac])
  195. +
  196. +if test "x$lt_cv_func_assert_works" = xyes; then
  197. + AC_CHECK_HEADERS(assert.h)
  198. +fi
  199. +])# AC_LIBTOOL_HEADER_ASSERT
  200. +
  201. +# _LT_AC_CHECK_DLFCN
  202. +# --------------------
  203. +AC_DEFUN([_LT_AC_CHECK_DLFCN],
  204. +[AC_CHECK_HEADERS(dlfcn.h)
  205. +])# _LT_AC_CHECK_DLFCN
  206. +
  207. +# AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
  208. +# ---------------------------------
  209. +AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
  210. +[AC_REQUIRE([AC_CANONICAL_HOST])
  211. +AC_REQUIRE([AC_PROG_NM])
  212. +AC_REQUIRE([AC_OBJEXT])
  213. +# Check for command to grab the raw symbol name followed by C symbol from nm.
  214. +AC_MSG_CHECKING([command to parse $NM output])
  215. +AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [dnl
  216. +
  217. +# These are sane defaults that work on at least a few old systems.
  218. +# [They come from Ultrix. What could be older than Ultrix?!! ;)]
  219. +
  220. +# Character class describing NM global symbol codes.
  221. +symcode='[[BCDEGRST]]'
  222. +
  223. +# Regexp to match symbols that can be accessed directly from C.
  224. +sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)'
  225. +
  226. +# Transform the above into a raw symbol and a C symbol.
  227. +symxfrm='\1 \2\3 \3'
  228. +
  229. +# Transform an extracted symbol line into a proper C declaration
  230. +lt_cv_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern char \1;/p'"
  231. +
  232. +# Transform an extracted symbol line into symbol name and symbol address
  233. +lt_cv_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
  234. +
  235. +# Define system-specific variables.
  236. +case $host_os in
  237. +aix*)
  238. + symcode='[[BCDT]]'
  239. + ;;
  240. +cygwin* | mingw* | pw32*)
  241. + symcode='[[ABCDGISTW]]'
  242. + ;;
  243. +hpux*) # Its linker distinguishes data from code symbols
  244. + lt_cv_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern char \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
  245. + lt_cv_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'"
  246. + ;;
  247. +irix* | nonstopux*)
  248. + symcode='[[BCDEGRST]]'
  249. + ;;
  250. +osf*)
  251. + symcode='[[BCDEGQRST]]'
  252. + ;;
  253. +solaris* | sysv5*)
  254. + symcode='[[BDT]]'
  255. + ;;
  256. +sysv4)
  257. + symcode='[[DFNSTU]]'
  258. + ;;
  259. +esac
  260. +
  261. +# Handle CRLF in mingw tool chain
  262. +opt_cr=
  263. +case $host_os in
  264. +mingw*)
  265. + opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
  266. + ;;
  267. +esac
  268. +
  269. +# If we're using GNU nm, then use its standard symbol codes.
  270. +if $NM -V 2>&1 | egrep '(GNU|with BFD)' > /dev/null; then
  271. + symcode='[[ABCDGISTW]]'
  272. +fi
  273. +
  274. +# Try without a prefix undercore, then with it.
  275. +for ac_symprfx in "" "_"; do
  276. +
  277. + # Write the raw and C identifiers.
  278. +lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*\($ac_symprfx\)$sympat$opt_cr$/$symxfrm/p'"
  279. +
  280. + # Check to see that the pipe works correctly.
  281. + pipe_works=no
  282. + rm -f conftest*
  283. + cat > conftest.$ac_ext <<EOF
  284. +#ifdef __cplusplus
  285. +extern "C" {
  286. +#endif
  287. +char nm_test_var;
  288. +void nm_test_func(){}
  289. +#ifdef __cplusplus
  290. +}
  291. +#endif
  292. +int main(){nm_test_var='a';nm_test_func();return(0);}
  293. +EOF
  294. +
  295. + if AC_TRY_EVAL(ac_compile); then
  296. + # Now try to grab the symbols.
  297. + nlist=conftest.nm
  298. + if AC_TRY_EVAL(NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) && test -s "$nlist"; then
  299. + # Try sorting and uniquifying the output.
  300. + if sort "$nlist" | uniq > "$nlist"T; then
  301. + mv -f "$nlist"T "$nlist"
  302. + else
  303. + rm -f "$nlist"T
  304. + fi
  305. +
  306. + # Make sure that we snagged all the symbols we need.
  307. + if egrep ' nm_test_var$' "$nlist" >/dev/null; then
  308. + if egrep ' nm_test_func$' "$nlist" >/dev/null; then
  309. + cat <<EOF > conftest.$ac_ext
  310. +#ifdef __cplusplus
  311. +extern "C" {
  312. +#endif
  313. +
  314. +EOF
  315. + # Now generate the symbol file.
  316. + eval "$lt_cv_global_symbol_to_cdecl"' < "$nlist" >> conftest.$ac_ext'
  317. +
  318. + cat <<EOF >> conftest.$ac_ext
  319. +#if defined (__STDC__) && __STDC__
  320. +# define lt_ptr void *
  321. #else
  322. -#include <linux/if_arp.h>
  323. -#include <linux/if_ether.h>
  324. +# define lt_ptr char *
  325. +# define const
  326. #endif
  327. -#if (PF_PACKET)
  328. -#ifndef SOL_PACKET
  329. -#define SOL_PACKET 263
  330. -#endif /* SOL_PACKET */
  331. -#include <linux/if_packet.h>
  332. +
  333. +/* The mapping between symbol names and symbols. */
  334. +const struct {
  335. + const char *name;
  336. + lt_ptr address;
  337. +}
  338. +lt_preloaded_symbols[[]] =
  339. +{
  340. +EOF
  341. + sed "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr) \&\2},/" < "$nlist" >> conftest.$ac_ext
  342. + cat <<\EOF >> conftest.$ac_ext
  343. + {0, (lt_ptr) 0}
  344. +};
  345. +
  346. +#ifdef __cplusplus
  347. +}
  348. #endif
  349. -#include <stdlib.h>
  350. -#include <linux/sockios.h>
  351. +EOF
  352. + # Now try linking the two files.
  353. + mv conftest.$ac_objext conftstm.$ac_objext
  354. + save_LIBS="$LIBS"
  355. + save_CFLAGS="$CFLAGS"
  356. + LIBS="conftstm.$ac_objext"
  357. + CFLAGS="$CFLAGS$no_builtin_flag"
  358. + if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then
  359. + pipe_works=yes
  360. + fi
  361. + LIBS="$save_LIBS"
  362. + CFLAGS="$save_CFLAGS"
  363. + else
  364. + echo "cannot find nm_test_func in $nlist" >&AC_FD_CC
  365. + fi
  366. + else
  367. + echo "cannot find nm_test_var in $nlist" >&AC_FD_CC
  368. + fi
  369. + else
  370. + echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AC_FD_CC
  371. + fi
  372. + else
  373. + echo "$progname: failed program was:" >&AC_FD_CC
  374. + cat conftest.$ac_ext >&5
  375. + fi
  376. + rm -f conftest* conftst*
  377. -int
  378. -main()
  379. + # Do not use the global_symbol_pipe unless it works.
  380. + if test "$pipe_works" = yes; then
  381. + break
  382. + else
  383. + lt_cv_sys_global_symbol_pipe=
  384. + fi
  385. +done
  386. +])
  387. +global_symbol_pipe="$lt_cv_sys_global_symbol_pipe"
  388. +if test -z "$lt_cv_sys_global_symbol_pipe"; then
  389. + global_symbol_to_cdecl=
  390. + global_symbol_to_c_name_address=
  391. +else
  392. + global_symbol_to_cdecl="$lt_cv_global_symbol_to_cdecl"
  393. + global_symbol_to_c_name_address="$lt_cv_global_symbol_to_c_name_address"
  394. +fi
  395. +if test -z "$global_symbol_pipe$global_symbol_to_cdec$global_symbol_to_c_name_address";
  396. +then
  397. + AC_MSG_RESULT(failed)
  398. +else
  399. + AC_MSG_RESULT(ok)
  400. +fi
  401. +]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
  402. +
  403. +# _LT_AC_LIBTOOL_SYS_PATH_SEPARATOR
  404. +# ---------------------------------
  405. +AC_DEFUN([_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR],
  406. +[# Find the correct PATH separator. Usually this is `:', but
  407. +# DJGPP uses `;' like DOS.
  408. +if test "X${PATH_SEPARATOR+set}" != Xset; then
  409. + UNAME=${UNAME-`uname 2>/dev/null`}
  410. + case X$UNAME in
  411. + *-DOS) lt_cv_sys_path_separator=';' ;;
  412. + *) lt_cv_sys_path_separator=':' ;;
  413. + esac
  414. + PATH_SEPARATOR=$lt_cv_sys_path_separator
  415. +fi
  416. +])# _LT_AC_LIBTOOL_SYS_PATH_SEPARATOR
  417. +
  418. +# _LT_AC_PROG_ECHO_BACKSLASH
  419. +# --------------------------
  420. +# Add some code to the start of the generated configure script which
  421. +# will find an echo command which doesn't interpret backslashes.
  422. +AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH],
  423. +[ifdef([AC_DIVERSION_NOTICE], [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)],
  424. + [AC_DIVERT_PUSH(NOTICE)])
  425. +_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR
  426. +
  427. +# Check that we are running under the correct shell.
  428. +SHELL=${CONFIG_SHELL-/bin/sh}
  429. +
  430. +case X$ECHO in
  431. +X*--fallback-echo)
  432. + # Remove one level of quotation (which was required for Make).
  433. + ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','`
  434. + ;;
  435. +esac
  436. +
  437. +echo=${ECHO-echo}
  438. +if test "X[$]1" = X--no-reexec; then
  439. + # Discard the --no-reexec flag, and continue.
  440. + shift
  441. +elif test "X[$]1" = X--fallback-echo; then
  442. + # Avoid inline document here, it may be left over
  443. + :
  444. +elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then
  445. + # Yippee, $echo works!
  446. + :
  447. +else
  448. + # Restart under the correct shell.
  449. + exec $SHELL "[$]0" --no-reexec ${1+"[$]@"}
  450. +fi
  451. +
  452. +if test "X[$]1" = X--fallback-echo; then
  453. + # used as fallback echo
  454. + shift
  455. + cat <<EOF
  456. +$*
  457. +EOF
  458. + exit 0
  459. +fi
  460. +
  461. +# The HP-UX ksh and POSIX shell print the target directory to stdout
  462. +# if CDPATH is set.
  463. +if test "X${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
  464. +
  465. +if test -z "$ECHO"; then
  466. +if test "X${echo_test_string+set}" != Xset; then
  467. +# find a string as large as possible, as long as the shell can cope with it
  468. + for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do
  469. + # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
  470. + if (echo_test_string="`eval $cmd`") 2>/dev/null &&
  471. + echo_test_string="`eval $cmd`" &&
  472. + (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
  473. + then
  474. + break
  475. + fi
  476. + done
  477. +fi
  478. +
  479. +if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
  480. + echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
  481. + test "X$echo_testing_string" = "X$echo_test_string"; then
  482. + :
  483. +else
  484. + # The Solaris, AIX, and Digital Unix default echo programs unquote
  485. + # backslashes. This makes it impossible to quote backslashes using
  486. + # echo "$something" | sed 's/\\/\\\\/g'
  487. + #
  488. + # So, first we look for a working echo in the user's PATH.
  489. +
  490. + IFS="${IFS= }"; save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  491. + for dir in $PATH /usr/ucb; do
  492. + if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
  493. + test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
  494. + echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
  495. + test "X$echo_testing_string" = "X$echo_test_string"; then
  496. + echo="$dir/echo"
  497. + break
  498. + fi
  499. + done
  500. + IFS="$save_ifs"
  501. +
  502. + if test "X$echo" = Xecho; then
  503. + # We didn't find a better echo, so look for alternatives.
  504. + if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
  505. + echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
  506. + test "X$echo_testing_string" = "X$echo_test_string"; then
  507. + # This shell has a builtin print -r that does the trick.
  508. + echo='print -r'
  509. + elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
  510. + test "X$CONFIG_SHELL" != X/bin/ksh; then
  511. + # If we have ksh, try running configure again with it.
  512. + ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
  513. + export ORIGINAL_CONFIG_SHELL
  514. + CONFIG_SHELL=/bin/ksh
  515. + export CONFIG_SHELL
  516. + exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"}
  517. + else
  518. + # Try using printf.
  519. + echo='printf %s\n'
  520. + if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
  521. + echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
  522. + test "X$echo_testing_string" = "X$echo_test_string"; then
  523. + # Cool, printf works
  524. + :
  525. + elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
  526. + test "X$echo_testing_string" = 'X\t' &&
  527. + echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
  528. + test "X$echo_testing_string" = "X$echo_test_string"; then
  529. + CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
  530. + export CONFIG_SHELL
  531. + SHELL="$CONFIG_SHELL"
  532. + export SHELL
  533. + echo="$CONFIG_SHELL [$]0 --fallback-echo"
  534. + elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` &&
  535. + test "X$echo_testing_string" = 'X\t' &&
  536. + echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
  537. + test "X$echo_testing_string" = "X$echo_test_string"; then
  538. + echo="$CONFIG_SHELL [$]0 --fallback-echo"
  539. + else
  540. + # maybe with a smaller string...
  541. + prev=:
  542. +
  543. + for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do
  544. + if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
  545. + then
  546. + break
  547. + fi
  548. + prev="$cmd"
  549. + done
  550. +
  551. + if test "$prev" != 'sed 50q "[$]0"'; then
  552. + echo_test_string=`eval $prev`
  553. + export echo_test_string
  554. + exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"}
  555. + else
  556. + # Oops. We lost completely, so just stick with echo.
  557. + echo=echo
  558. + fi
  559. + fi
  560. + fi
  561. + fi
  562. +fi
  563. +fi
  564. +
  565. +# Copy echo and quote the copy suitably for passing to libtool from
  566. +# the Makefile, instead of quoting the original, which is used later.
  567. +ECHO=$echo
  568. +if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then
  569. + ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo"
  570. +fi
  571. +
  572. +AC_SUBST(ECHO)
  573. +AC_DIVERT_POP
  574. +])# _LT_AC_PROG_ECHO_BACKSLASH
  575. +
  576. +# _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
  577. +# ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
  578. +# ------------------------------------------------------------------
  579. +AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
  580. +[if test "$cross_compiling" = yes; then :
  581. + [$4]
  582. +else
  583. + AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
  584. + lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
  585. + lt_status=$lt_dlunknown
  586. + cat > conftest.$ac_ext <<EOF
  587. +[#line __oline__ "configure"
  588. +#include "confdefs.h"
  589. +
  590. +#if HAVE_DLFCN_H
  591. +#include <dlfcn.h>
  592. +#endif
  593. +
  594. +#include <stdio.h>
  595. +
  596. +#ifdef RTLD_GLOBAL
  597. +# define LT_DLGLOBAL RTLD_GLOBAL
  598. +#else
  599. +# ifdef DL_GLOBAL
  600. +# define LT_DLGLOBAL DL_GLOBAL
  601. +# else
  602. +# define LT_DLGLOBAL 0
  603. +# endif
  604. +#endif
  605. +
  606. +/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
  607. + find out it does not work in some platform. */
  608. +#ifndef LT_DLLAZY_OR_NOW
  609. +# ifdef RTLD_LAZY
  610. +# define LT_DLLAZY_OR_NOW RTLD_LAZY
  611. +# else
  612. +# ifdef DL_LAZY
  613. +# define LT_DLLAZY_OR_NOW DL_LAZY
  614. +# else
  615. +# ifdef RTLD_NOW
  616. +# define LT_DLLAZY_OR_NOW RTLD_NOW
  617. +# else
  618. +# ifdef DL_NOW
  619. +# define LT_DLLAZY_OR_NOW DL_NOW
  620. +# else
  621. +# define LT_DLLAZY_OR_NOW 0
  622. +# endif
  623. +# endif
  624. +# endif
  625. +# endif
  626. +#endif
  627. +
  628. +#ifdef __cplusplus
  629. +extern "C" void exit (int);
  630. +#endif
  631. +
  632. +void fnord() { int i=42;}
  633. +int main ()
  634. {
  635. -#if (PF_PACKET)
  636. - int fd;
  637. - struct sockaddr_ll sa;
  638. - struct ifreq ifr;
  639. - struct packet_mreq mr;
  640. - char *device ="lo";
  641. + void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
  642. + int status = $lt_dlunknown;
  643. - fd = socket(PF_PACKET, SOCK_RAW, htons(ETH_P_ALL));
  644. - if (fd == -1)
  645. + if (self)
  646. {
  647. - printf("choked");
  648. - exit (EXIT_FAILURE);
  649. + if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
  650. + else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
  651. + /* dlclose (self); */
  652. }
  653. - memset(&sa, 0, sizeof(sa));
  654. - strcpy(ifr.ifr_name, device);
  655. - if (ioctl(fd, SIOCGIFINDEX, &ifr) < 0)
  656. - {
  657. - printf("choked");
  658. - exit (EXIT_FAILURE);
  659. - }
  660. - sa.sll_family = AF_PACKET;
  661. - sa.sll_ifindex = ifr.ifr_ifindex;
  662. - sa.sll_protocol = htons(ETH_P_ALL);
  663. + exit (status);
  664. +}]
  665. +EOF
  666. + if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then
  667. + (./conftest; exit; ) 2>/dev/null
  668. + lt_status=$?
  669. + case x$lt_status in
  670. + x$lt_dlno_uscore) $1 ;;
  671. + x$lt_dlneed_uscore) $2 ;;
  672. + x$lt_unknown|x*) $3 ;;
  673. + esac
  674. + else :
  675. + # compilation failed
  676. + $3
  677. + fi
  678. +fi
  679. +rm -fr conftest*
  680. +])# _LT_AC_TRY_DLOPEN_SELF
  681. - memset(&mr, 0, sizeof (mr));
  682. - mr.mr_ifindex = sa.sll_ifindex;
  683. - mr.mr_type = PACKET_MR_ALLMULTI;
  684. +# AC_LIBTOOL_DLOPEN_SELF
  685. +# -------------------
  686. +AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
  687. +[if test "x$enable_dlopen" != xyes; then
  688. + enable_dlopen=unknown
  689. + enable_dlopen_self=unknown
  690. + enable_dlopen_self_static=unknown
  691. +else
  692. + lt_cv_dlopen=no
  693. + lt_cv_dlopen_libs=
  694. +
  695. + case $host_os in
  696. + beos*)
  697. + lt_cv_dlopen="load_add_on"
  698. + lt_cv_dlopen_libs=
  699. + lt_cv_dlopen_self=yes
  700. + ;;
  701. +
  702. + cygwin* | mingw* | pw32*)
  703. + lt_cv_dlopen="LoadLibrary"
  704. + lt_cv_dlopen_libs=
  705. + ;;
  706. +
  707. + *)
  708. + AC_CHECK_FUNC([shl_load],
  709. + [lt_cv_dlopen="shl_load"],
  710. + [AC_CHECK_LIB([dld], [shl_load],
  711. + [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
  712. + [AC_CHECK_FUNC([dlopen],
  713. + [lt_cv_dlopen="dlopen"],
  714. + [AC_CHECK_LIB([dl], [dlopen],
  715. + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],
  716. + [AC_CHECK_LIB([svld], [dlopen],
  717. + [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
  718. + [AC_CHECK_LIB([dld], [dld_link],
  719. + [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
  720. + ])
  721. + ])
  722. + ])
  723. + ])
  724. + ])
  725. + ;;
  726. + esac
  727. +
  728. + if test "x$lt_cv_dlopen" != xno; then
  729. + enable_dlopen=yes
  730. + else
  731. + enable_dlopen=no
  732. + fi
  733. +
  734. + case $lt_cv_dlopen in
  735. + dlopen)
  736. + save_CPPFLAGS="$CPPFLAGS"
  737. + AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
  738. + test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
  739. +
  740. + save_LDFLAGS="$LDFLAGS"
  741. + eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
  742. +
  743. + save_LIBS="$LIBS"
  744. + LIBS="$lt_cv_dlopen_libs $LIBS"
  745. +
  746. + AC_CACHE_CHECK([whether a program can dlopen itself],
  747. + lt_cv_dlopen_self, [dnl
  748. + _LT_AC_TRY_DLOPEN_SELF(
  749. + lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes,
  750. + lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross)
  751. + ])
  752. +
  753. + if test "x$lt_cv_dlopen_self" = xyes; then
  754. + LDFLAGS="$LDFLAGS $link_static_flag"
  755. + AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
  756. + lt_cv_dlopen_self_static, [dnl
  757. + _LT_AC_TRY_DLOPEN_SELF(
  758. + lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes,
  759. + lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross)
  760. + ])
  761. + fi
  762. +
  763. + CPPFLAGS="$save_CPPFLAGS"
  764. + LDFLAGS="$save_LDFLAGS"
  765. + LIBS="$save_LIBS"
  766. + ;;
  767. + esac
  768. +
  769. + case $lt_cv_dlopen_self in
  770. + yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
  771. + *) enable_dlopen_self=unknown ;;
  772. + esac
  773. +
  774. + case $lt_cv_dlopen_self_static in
  775. + yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
  776. + *) enable_dlopen_self_static=unknown ;;
  777. + esac
  778. +fi
  779. +])# AC_LIBTOOL_DLOPEN_SELF
  780. +
  781. +AC_DEFUN([_LT_AC_LTCONFIG_HACK],
  782. +[AC_REQUIRE([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])dnl
  783. +# Sed substitution that helps us do robust quoting. It backslashifies
  784. +# metacharacters that are still active within double-quoted strings.
  785. +Xsed='sed -e s/^X//'
  786. +sed_quote_subst='s/\([[\\"\\`$\\\\]]\)/\\\1/g'
  787. +
  788. +# Same as above, but do not quote variable references.
  789. +double_quote_subst='s/\([[\\"\\`\\\\]]\)/\\\1/g'
  790. +
  791. +# Sed substitution to delay expansion of an escaped shell variable in a
  792. +# double_quote_subst'ed string.
  793. +delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
  794. +
  795. +# Constants:
  796. +rm="rm -f"
  797. +
  798. +# Global variables:
  799. +default_ofile=libtool
  800. +can_build_shared=yes
  801. +
  802. +# All known linkers require a `.a' archive for static linking (except M$VC,
  803. +# which needs '.lib').
  804. +libext=a
  805. +ltmain="$ac_aux_dir/ltmain.sh"
  806. +ofile="$default_ofile"
  807. +with_gnu_ld="$lt_cv_prog_gnu_ld"
  808. +need_locks="$enable_libtool_lock"
  809. +
  810. +old_CC="$CC"
  811. +old_CFLAGS="$CFLAGS"
  812. +
  813. +# Set sane defaults for various variables
  814. +test -z "$AR" && AR=ar
  815. +test -z "$AR_FLAGS" && AR_FLAGS=cru
  816. +test -z "$AS" && AS=as
  817. +test -z "$CC" && CC=cc
  818. +test -z "$DLLTOOL" && DLLTOOL=dlltool
  819. +test -z "$LD" && LD=ld
  820. +test -z "$LN_S" && LN_S="ln -s"
  821. +test -z "$MAGIC_CMD" && MAGIC_CMD=file
  822. +test -z "$NM" && NM=nm
  823. +test -z "$OBJDUMP" && OBJDUMP=objdump
  824. +test -z "$RANLIB" && RANLIB=:
  825. +test -z "$STRIP" && STRIP=:
  826. +test -z "$ac_objext" && ac_objext=o
  827. +
  828. +if test x"$host" != x"$build"; then
  829. + ac_tool_prefix=${host_alias}-
  830. +else
  831. + ac_tool_prefix=
  832. +fi
  833. +
  834. +# Transform linux* to *-*-linux-gnu*, to support old configure scripts.
  835. +case $host_os in
  836. +linux-gnu*) ;;
  837. +linux*) host=`echo $host | sed 's/^\(.*-.*-linux\)\(.*\)$/\1-gnu\2/'`
  838. +esac
  839. +
  840. +case $host_os in
  841. +aix3*)
  842. + # AIX sometimes has problems with the GCC collect2 program. For some
  843. + # reason, if we set the COLLECT_NAMES environment variable, the problems
  844. + # vanish in a puff of smoke.
  845. + if test "X${COLLECT_NAMES+set}" != Xset; then
  846. + COLLECT_NAMES=
  847. + export COLLECT_NAMES
  848. + fi
  849. + ;;
  850. +esac
  851. +
  852. +# Determine commands to create old-style static archives.
  853. +old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
  854. +old_postinstall_cmds='chmod 644 $oldlib'
  855. +old_postuninstall_cmds=
  856. +
  857. +if test -n "$RANLIB"; then
  858. + case $host_os in
  859. + openbsd*)
  860. + old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
  861. + ;;
  862. + *)
  863. + old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
  864. + ;;
  865. + esac
  866. + old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
  867. +fi
  868. +
  869. +# Allow CC to be a program name with arguments.
  870. +set dummy $CC
  871. +compiler="[$]2"
  872. +
  873. +AC_MSG_CHECKING([for objdir])
  874. +rm -f .libs 2>/dev/null
  875. +mkdir .libs 2>/dev/null
  876. +if test -d .libs; then
  877. + objdir=.libs
  878. +else
  879. + # MS-DOS does not allow filenames that begin with a dot.
  880. + objdir=_libs
  881. +fi
  882. +rmdir .libs 2>/dev/null
  883. +AC_MSG_RESULT($objdir)
  884. +
  885. +
  886. +AC_ARG_WITH(pic,
  887. +[ --with-pic try to use only PIC/non-PIC objects [default=use both]],
  888. +pic_mode="$withval", pic_mode=default)
  889. +test -z "$pic_mode" && pic_mode=default
  890. +
  891. +# We assume here that the value for lt_cv_prog_cc_pic will not be cached
  892. +# in isolation, and that seeing it set (from the cache) indicates that
  893. +# the associated values are set (in the cache) correctly too.
  894. +AC_MSG_CHECKING([for $compiler option to produce PIC])
  895. +AC_CACHE_VAL(lt_cv_prog_cc_pic,
  896. +[ lt_cv_prog_cc_pic=
  897. + lt_cv_prog_cc_shlib=
  898. + lt_cv_prog_cc_wl=
  899. + lt_cv_prog_cc_static=
  900. + lt_cv_prog_cc_no_builtin=
  901. + lt_cv_prog_cc_can_build_shared=$can_build_shared
  902. +
  903. + if test "$GCC" = yes; then
  904. + lt_cv_prog_cc_wl='-Wl,'
  905. + lt_cv_prog_cc_static='-static'
  906. +
  907. + case $host_os in
  908. + aix*)
  909. + # Below there is a dirty hack to force normal static linking with -ldl
  910. + # The problem is because libdl dynamically linked with both libc and
  911. + # libC (AIX C++ library), which obviously doesn't included in libraries
  912. + # list by gcc. This cause undefined symbols with -static flags.
  913. + # This hack allows C programs to be linked with "-static -ldl", but
  914. + # not sure about C++ programs.
  915. + lt_cv_prog_cc_static="$lt_cv_prog_cc_static ${lt_cv_prog_cc_wl}-lC"
  916. + ;;
  917. + amigaos*)
  918. + # FIXME: we need at least 68020 code to build shared libraries, but
  919. + # adding the `-m68020' flag to GCC prevents building anything better,
  920. + # like `-m68040'.
  921. + lt_cv_prog_cc_pic='-m68020 -resident32 -malways-restore-a4'
  922. + ;;
  923. + beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
  924. + # PIC is the default for these OSes.
  925. + ;;
  926. + darwin* | rhapsody*)
  927. + # PIC is the default on this platform
  928. + # Common symbols not allowed in MH_DYLIB files
  929. + lt_cv_prog_cc_pic='-fno-common'
  930. + ;;
  931. + cygwin* | mingw* | pw32* | os2*)
  932. + # This hack is so that the source file can tell whether it is being
  933. + # built for inclusion in a dll (and should export symbols for example).
  934. + lt_cv_prog_cc_pic='-DDLL_EXPORT'
  935. + ;;
  936. + sysv4*MP*)
  937. + if test -d /usr/nec; then
  938. + lt_cv_prog_cc_pic=-Kconform_pic
  939. + fi
  940. + ;;
  941. + *)
  942. + lt_cv_prog_cc_pic='-fPIC'
  943. + ;;
  944. + esac
  945. + else
  946. + # PORTME Check for PIC flags for the system compiler.
  947. + case $host_os in
  948. + aix3* | aix4* | aix5*)
  949. + lt_cv_prog_cc_wl='-Wl,'
  950. + # All AIX code is PIC.
  951. + if test "$host_cpu" = ia64; then
  952. + # AIX 5 now supports IA64 processor
  953. + lt_cv_prog_cc_static='-Bstatic'
  954. + else
  955. + lt_cv_prog_cc_static='-bnso -bI:/lib/syscalls.exp'
  956. + fi
  957. + ;;
  958. +
  959. + hpux9* | hpux10* | hpux11*)
  960. + # Is there a better lt_cv_prog_cc_static that works with the bundled CC?
  961. + lt_cv_prog_cc_wl='-Wl,'
  962. + lt_cv_prog_cc_static="${lt_cv_prog_cc_wl}-a ${lt_cv_prog_cc_wl}archive"
  963. + lt_cv_prog_cc_pic='+Z'
  964. + ;;
  965. +
  966. + irix5* | irix6* | nonstopux*)
  967. + lt_cv_prog_cc_wl='-Wl,'
  968. + lt_cv_prog_cc_static='-non_shared'
  969. + # PIC (with -KPIC) is the default.
  970. + ;;
  971. +
  972. + cygwin* | mingw* | pw32* | os2*)
  973. + # This hack is so that the source file can tell whether it is being
  974. + # built for inclusion in a dll (and should export symbols for example).
  975. + lt_cv_prog_cc_pic='-DDLL_EXPORT'
  976. + ;;
  977. +
  978. + newsos6)
  979. + lt_cv_prog_cc_pic='-KPIC'
  980. + lt_cv_prog_cc_static='-Bstatic'
  981. + ;;
  982. +
  983. + osf3* | osf4* | osf5*)
  984. + # All OSF/1 code is PIC.
  985. + lt_cv_prog_cc_wl='-Wl,'
  986. + lt_cv_prog_cc_static='-non_shared'
  987. + ;;
  988. +
  989. + sco3.2v5*)
  990. + lt_cv_prog_cc_pic='-Kpic'
  991. + lt_cv_prog_cc_static='-dn'
  992. + lt_cv_prog_cc_shlib='-belf'
  993. + ;;
  994. +
  995. + solaris*)
  996. + lt_cv_prog_cc_pic='-KPIC'
  997. + lt_cv_prog_cc_static='-Bstatic'
  998. + lt_cv_prog_cc_wl='-Wl,'
  999. + ;;
  1000. +
  1001. + sunos4*)
  1002. + lt_cv_prog_cc_pic='-PIC'
  1003. + lt_cv_prog_cc_static='-Bstatic'
  1004. + lt_cv_prog_cc_wl='-Qoption ld '
  1005. + ;;
  1006. +
  1007. + sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
  1008. + lt_cv_prog_cc_pic='-KPIC'
  1009. + lt_cv_prog_cc_static='-Bstatic'
  1010. + lt_cv_prog_cc_wl='-Wl,'
  1011. + ;;
  1012. +
  1013. + uts4*)
  1014. + lt_cv_prog_cc_pic='-pic'
  1015. + lt_cv_prog_cc_static='-Bstatic'
  1016. + ;;
  1017. +
  1018. + sysv4*MP*)
  1019. + if test -d /usr/nec ;then
  1020. + lt_cv_prog_cc_pic='-Kconform_pic'
  1021. + lt_cv_prog_cc_static='-Bstatic'
  1022. + fi
  1023. + ;;
  1024. +
  1025. + *)
  1026. + lt_cv_prog_cc_can_build_shared=no
  1027. + ;;
  1028. + esac
  1029. + fi
  1030. +])
  1031. +if test -z "$lt_cv_prog_cc_pic"; then
  1032. + AC_MSG_RESULT([none])
  1033. +else
  1034. + AC_MSG_RESULT([$lt_cv_prog_cc_pic])
  1035. +
  1036. + # Check to make sure the pic_flag actually works.
  1037. + AC_MSG_CHECKING([if $compiler PIC flag $lt_cv_prog_cc_pic works])
  1038. + AC_CACHE_VAL(lt_cv_prog_cc_pic_works, [dnl
  1039. + save_CFLAGS="$CFLAGS"
  1040. + CFLAGS="$CFLAGS $lt_cv_prog_cc_pic -DPIC"
  1041. + AC_TRY_COMPILE([], [], [dnl
  1042. + case $host_os in
  1043. + hpux9* | hpux10* | hpux11*)
  1044. + # On HP-UX, both CC and GCC only warn that PIC is supported... then
  1045. + # they create non-PIC objects. So, if there were any warnings, we
  1046. + # assume that PIC is not supported.
  1047. + if test -s conftest.err; then
  1048. + lt_cv_prog_cc_pic_works=no
  1049. + else
  1050. + lt_cv_prog_cc_pic_works=yes
  1051. + fi
  1052. + ;;
  1053. + *)
  1054. + lt_cv_prog_cc_pic_works=yes
  1055. + ;;
  1056. + esac
  1057. + ], [dnl
  1058. + lt_cv_prog_cc_pic_works=no
  1059. + ])
  1060. + CFLAGS="$save_CFLAGS"
  1061. + ])
  1062. +
  1063. + if test "X$lt_cv_prog_cc_pic_works" = Xno; then
  1064. + lt_cv_prog_cc_pic=
  1065. + lt_cv_prog_cc_can_build_shared=no
  1066. + else
  1067. + lt_cv_prog_cc_pic=" $lt_cv_prog_cc_pic"
  1068. + fi
  1069. +
  1070. + AC_MSG_RESULT([$lt_cv_prog_cc_pic_works])
  1071. +fi
  1072. +
  1073. +# Check for any special shared library compilation flags.
  1074. +if test -n "$lt_cv_prog_cc_shlib"; then
  1075. + AC_MSG_WARN([\`$CC' requires \`$lt_cv_prog_cc_shlib' to build shared libraries])
  1076. + if echo "$old_CC $old_CFLAGS " | egrep -e "[[ ]]$lt_cv_prog_cc_shlib[[ ]]" >/dev/null; then :
  1077. + else
  1078. + AC_MSG_WARN([add \`$lt_cv_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure])
  1079. + lt_cv_prog_cc_can_build_shared=no
  1080. + fi
  1081. +fi
  1082. +
  1083. +AC_MSG_CHECKING([if $compiler static flag $lt_cv_prog_cc_static works])
  1084. +AC_CACHE_VAL([lt_cv_prog_cc_static_works], [dnl
  1085. + lt_cv_prog_cc_static_works=no
  1086. + save_LDFLAGS="$LDFLAGS"
  1087. + LDFLAGS="$LDFLAGS $lt_cv_prog_cc_static"
  1088. + AC_TRY_LINK([], [], [lt_cv_prog_cc_static_works=yes])
  1089. + LDFLAGS="$save_LDFLAGS"
  1090. +])
  1091. +
  1092. +# Belt *and* braces to stop my trousers falling down:
  1093. +test "X$lt_cv_prog_cc_static_works" = Xno && lt_cv_prog_cc_static=
  1094. +AC_MSG_RESULT([$lt_cv_prog_cc_static_works])
  1095. +
  1096. +pic_flag="$lt_cv_prog_cc_pic"
  1097. +special_shlib_compile_flags="$lt_cv_prog_cc_shlib"
  1098. +wl="$lt_cv_prog_cc_wl"
  1099. +link_static_flag="$lt_cv_prog_cc_static"
  1100. +no_builtin_flag="$lt_cv_prog_cc_no_builtin"
  1101. +can_build_shared="$lt_cv_prog_cc_can_build_shared"
  1102. +
  1103. +
  1104. +# Check to see if options -o and -c are simultaneously supported by compiler
  1105. +AC_MSG_CHECKING([if $compiler supports -c -o file.$ac_objext])
  1106. +AC_CACHE_VAL([lt_cv_compiler_c_o], [
  1107. +$rm -r conftest 2>/dev/null
  1108. +mkdir conftest
  1109. +cd conftest
  1110. +echo "int some_variable = 0;" > conftest.$ac_ext
  1111. +mkdir out
  1112. +# According to Tom Tromey, Ian Lance Taylor reported there are C compilers
  1113. +# that will create temporary files in the current directory regardless of
  1114. +# the output directory. Thus, making CWD read-only will cause this test
  1115. +# to fail, enabling locking or at least warning the user not to do parallel
  1116. +# builds.
  1117. +chmod -w .
  1118. +save_CFLAGS="$CFLAGS"
  1119. +CFLAGS="$CFLAGS -o out/conftest2.$ac_objext"
  1120. +compiler_c_o=no
  1121. +if { (eval echo configure:__oline__: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>out/conftest.err; } && test -s out/conftest2.$ac_objext; then
  1122. + # The compiler can only warn and ignore the option if not recognized
  1123. + # So say no if there are warnings
  1124. + if test -s out/conftest.err; then
  1125. + lt_cv_compiler_c_o=no
  1126. + else
  1127. + lt_cv_compiler_c_o=yes
  1128. + fi
  1129. +else
  1130. + # Append any errors to the config.log.
  1131. + cat out/conftest.err 1>&AC_FD_CC
  1132. + lt_cv_compiler_c_o=no
  1133. +fi
  1134. +CFLAGS="$save_CFLAGS"
  1135. +chmod u+w .
  1136. +$rm conftest* out/*
  1137. +rmdir out
  1138. +cd ..
  1139. +rmdir conftest
  1140. +$rm -r conftest 2>/dev/null
  1141. +])
  1142. +compiler_c_o=$lt_cv_compiler_c_o
  1143. +AC_MSG_RESULT([$compiler_c_o])
  1144. +
  1145. +if test x"$compiler_c_o" = x"yes"; then
  1146. + # Check to see if we can write to a .lo
  1147. + AC_MSG_CHECKING([if $compiler supports -c -o file.lo])
  1148. + AC_CACHE_VAL([lt_cv_compiler_o_lo], [
  1149. + lt_cv_compiler_o_lo=no
  1150. + save_CFLAGS="$CFLAGS"
  1151. + CFLAGS="$CFLAGS -c -o conftest.lo"
  1152. + save_objext="$ac_objext"
  1153. + ac_objext=lo
  1154. + AC_TRY_COMPILE([], [int some_variable = 0;], [dnl
  1155. + # The compiler can only warn and ignore the option if not recognized
  1156. + # So say no if there are warnings
  1157. + if test -s conftest.err; then
  1158. + lt_cv_compiler_o_lo=no
  1159. + else
  1160. + lt_cv_compiler_o_lo=yes
  1161. + fi
  1162. + ])
  1163. + ac_objext="$save_objext"
  1164. + CFLAGS="$save_CFLAGS"
  1165. + ])
  1166. + compiler_o_lo=$lt_cv_compiler_o_lo
  1167. + AC_MSG_RESULT([$compiler_o_lo])
  1168. +else
  1169. + compiler_o_lo=no
  1170. +fi
  1171. +
  1172. +# Check to see if we can do hard links to lock some files if needed
  1173. +hard_links="nottested"
  1174. +if test "$compiler_c_o" = no && test "$need_locks" != no; then
  1175. + # do not overwrite the value of need_locks provided by the user
  1176. + AC_MSG_CHECKING([if we can lock with hard links])
  1177. + hard_links=yes
  1178. + $rm conftest*
  1179. + ln conftest.a conftest.b 2>/dev/null && hard_links=no
  1180. + touch conftest.a
  1181. + ln conftest.a conftest.b 2>&5 || hard_links=no
  1182. + ln conftest.a conftest.b 2>/dev/null && hard_links=no
  1183. + AC_MSG_RESULT([$hard_links])
  1184. + if test "$hard_links" = no; then
  1185. + AC_MSG_WARN([\`$CC' does not support \`-c -o', so \`make -j' may be unsafe])
  1186. + need_locks=warn
  1187. + fi
  1188. +else
  1189. + need_locks=no
  1190. +fi
  1191. +
  1192. +if test "$GCC" = yes; then
  1193. + # Check to see if options -fno-rtti -fno-exceptions are supported by compiler
  1194. + AC_MSG_CHECKING([if $compiler supports -fno-rtti -fno-exceptions])
  1195. + echo "int some_variable = 0;" > conftest.$ac_ext
  1196. + save_CFLAGS="$CFLAGS"
  1197. + CFLAGS="$CFLAGS -fno-rtti -fno-exceptions -c conftest.$ac_ext"
  1198. + compiler_rtti_exceptions=no
  1199. + AC_TRY_COMPILE([], [int some_variable = 0;], [dnl
  1200. + # The compiler can only warn and ignore the option if not recognized
  1201. + # So say no if there are warnings
  1202. + if test -s conftest.err; then
  1203. + compiler_rtti_exceptions=no
  1204. + else
  1205. + compiler_rtti_exceptions=yes
  1206. + fi
  1207. + ])
  1208. + CFLAGS="$save_CFLAGS"
  1209. + AC_MSG_RESULT([$compiler_rtti_exceptions])
  1210. +
  1211. + if test "$compiler_rtti_exceptions" = "yes"; then
  1212. + no_builtin_flag=' -fno-builtin -fno-rtti -fno-exceptions'
  1213. + else
  1214. + no_builtin_flag=' -fno-builtin'
  1215. + fi
  1216. +fi
  1217. +
  1218. +# See if the linker supports building shared libraries.
  1219. +AC_MSG_CHECKING([whether the linker ($LD) supports shared libraries])
  1220. +
  1221. +allow_undefined_flag=
  1222. +no_undefined_flag=
  1223. +need_lib_prefix=unknown
  1224. +need_version=unknown
  1225. +# when you set need_version to no, make sure it does not cause -set_version
  1226. +# flags to be left without arguments
  1227. +archive_cmds=
  1228. +archive_expsym_cmds=
  1229. +old_archive_from_new_cmds=
  1230. +old_archive_from_expsyms_cmds=
  1231. +export_dynamic_flag_spec=
  1232. +whole_archive_flag_spec=
  1233. +thread_safe_flag_spec=
  1234. +hardcode_into_libs=no
  1235. +hardcode_libdir_flag_spec=
  1236. +hardcode_libdir_separator=
  1237. +hardcode_direct=no
  1238. +hardcode_minus_L=no
  1239. +hardcode_shlibpath_var=unsupported
  1240. +runpath_var=
  1241. +link_all_deplibs=unknown
  1242. +always_export_symbols=no
  1243. +export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | sed '\''s/.* //'\'' | sort | uniq > $export_symbols'
  1244. +# include_expsyms should be a list of space-separated symbols to be *always*
  1245. +# included in the symbol list
  1246. +include_expsyms=
  1247. +# exclude_expsyms can be an egrep regular expression of symbols to exclude
  1248. +# it will be wrapped by ` (' and `)$', so one must not match beginning or
  1249. +# end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
  1250. +# as well as any symbol that contains `d'.
  1251. +exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
  1252. +# Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
  1253. +# platforms (ab)use it in PIC code, but their linkers get confused if
  1254. +# the symbol is explicitly referenced. Since portable code cannot
  1255. +# rely on this symbol name, it's probably fine to never include it in
  1256. +# preloaded symbol tables.
  1257. +extract_expsyms_cmds=
  1258. +
  1259. +case $host_os in
  1260. +cygwin* | mingw* | pw32*)
  1261. + # FIXME: the MSVC++ port hasn't been tested in a loooong time
  1262. + # When not using gcc, we currently assume that we are using
  1263. + # Microsoft Visual C++.
  1264. + if test "$GCC" != yes; then
  1265. + with_gnu_ld=no
  1266. + fi
  1267. + ;;
  1268. +openbsd*)
  1269. + with_gnu_ld=no
  1270. + ;;
  1271. +esac
  1272. +
  1273. +ld_shlibs=yes
  1274. +if test "$with_gnu_ld" = yes; then
  1275. + # If archive_cmds runs LD, not CC, wlarc should be empty
  1276. + wlarc='${wl}'
  1277. +
  1278. + # See if GNU ld supports shared libraries.
  1279. + case $host_os in
  1280. + aix3* | aix4* | aix5*)
  1281. + # On AIX, the GNU linker is very broken
  1282. + # Note:Check GNU linker on AIX 5-IA64 when/if it becomes available.
  1283. + ld_shlibs=no
  1284. + cat <<EOF 1>&2
  1285. +
  1286. +*** Warning: the GNU linker, at least up to release 2.9.1, is reported
  1287. +*** to be unable to reliably create shared libraries on AIX.
  1288. +*** Therefore, libtool is disabling shared libraries support. If you
  1289. +*** really care for shared libraries, you may want to modify your PATH
  1290. +*** so that a non-GNU linker is found, and then restart.
  1291. - if (setsockopt(fd, SOL_PACKET, PACKET_ADD_MEMBERSHIP, (char *)&mr,
  1292. - sizeof (mr)) < 0)
  1293. - {
  1294. - printf("choked\n");
  1295. - exit (EXIT_FAILURE);
  1296. - }
  1297. - /* yay. we made it and it workz! */
  1298. - printf("yes");
  1299. -#else /* PF_PACKET */
  1300. - printf("no");
  1301. -#endif
  1302. - exit (EXIT_SUCCESS);
  1303. -}
  1304. EOF
  1305. - ${CC-cc} -o pf_packet-test $CFLAGS pf_packet-test.c >/dev/null 2>&1
  1306. + ;;
  1307. - # Oopz 4.3 BSD doesn't have this. Sorry.
  1308. - if test ! -x ./pf_packet-test ; then
  1309. - ac_libnet_have_pf_packet=choked
  1310. + amigaos*)
  1311. + archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
  1312. + hardcode_libdir_flag_spec='-L$libdir'
  1313. + hardcode_minus_L=yes
  1314. +
  1315. + # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
  1316. + # that the semantics of dynamic libraries on AmigaOS, at least up
  1317. + # to version 4, is to share data among multiple programs linked
  1318. + # with the same dynamic library. Since this doesn't match the
  1319. + # behavior of shared libraries on other platforms, we can use
  1320. + # them.
  1321. + ld_shlibs=no
  1322. + ;;
  1323. +
  1324. + beos*)
  1325. + if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
  1326. + allow_undefined_flag=unsupported
  1327. + # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
  1328. + # support --undefined. This deserves some investigation. FIXME
  1329. + archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  1330. else
  1331. - ac_libnet_have_pf_packet=`./pf_packet-test`;
  1332. + ld_shlibs=no
  1333. fi
  1334. + ;;
  1335. - if test $ac_libnet_have_pf_packet = choked; then
  1336. - AC_MSG_RESULT(test program choked... assuming no)
  1337. - elif test $ac_libnet_have_pf_packet = yes; then
  1338. - AC_DEFINE(HAVE_PF_PACKET)
  1339. - LIBNET_CONFIG_DEFINES="$LIBNET_CONFIG_DEFINES -DHAVE_PF_PACKET"
  1340. + cygwin* | mingw* | pw32*)
  1341. + # hardcode_libdir_flag_spec is actually meaningless, as there is
  1342. + # no search path for DLLs.
  1343. + hardcode_libdir_flag_spec='-L$libdir'
  1344. + allow_undefined_flag=unsupported
  1345. + always_export_symbols=yes
  1346. +
  1347. + extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
  1348. + sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //;s/^# *$//; p; }" -e d < $''0 > $output_objdir/impgen.c~
  1349. + test -f $output_objdir/impgen.exe || (cd $output_objdir && \
  1350. + if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
  1351. + else $CC -o impgen impgen.c ; fi)~
  1352. + $output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
  1353. +
  1354. + old_archive_from_expsyms_cmds='$DLLTOOL --as=$AS --dllname $soname --def $output_objdir/$soname-def --output-lib $output_objdir/$newlib'
  1355. +
  1356. + # cygwin and mingw dlls have different entry points and sets of symbols
  1357. + # to exclude.
  1358. + # FIXME: what about values for MSVC?
  1359. + dll_entry=__cygwin_dll_entry@12
  1360. + dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12~
  1361. + case $host_os in
  1362. + mingw*)
  1363. + # mingw values
  1364. + dll_entry=_DllMainCRTStartup@12
  1365. + dll_exclude_symbols=DllMain@12,DllMainCRTStartup@12,DllEntryPoint@12~
  1366. + ;;
  1367. + esac
  1368. +
  1369. + # mingw and cygwin differ, and it's simplest to just exclude the union
  1370. + # of the two symbol sets.
  1371. + dll_exclude_symbols=DllMain@12,_cygwin_dll_entry@12,_cygwin_noncygwin_dll_entry@12,DllMainCRTStartup@12,DllEntryPoint@12
  1372. +
  1373. + # recent cygwin and mingw systems supply a stub DllMain which the user
  1374. + # can override, but on older systems we have to supply one (in ltdll.c)
  1375. + if test "x$lt_cv_need_dllmain" = "xyes"; then
  1376. + ltdll_obj='$output_objdir/$soname-ltdll.'"$ac_objext "
  1377. + ltdll_cmds='test -f $output_objdir/$soname-ltdll.c || sed -e "/^# \/\* ltdll\.c starts here \*\//,/^# \/\* ltdll.c ends here \*\// { s/^# //; p; }" -e d < $''0 > $output_objdir/$soname-ltdll.c~
  1378. + test -f $output_objdir/$soname-ltdll.$ac_objext || (cd $output_objdir && $CC -c $soname-ltdll.c)~'
  1379. + else
  1380. + ltdll_obj=
  1381. + ltdll_cmds=
  1382. fi
  1383. - if test $ac_libnet_have_pf_packet != choked; then
  1384. - AC_MSG_RESULT($ac_libnet_have_pf_packet)
  1385. + # Extract the symbol export list from an `--export-all' def file,
  1386. + # then regenerate the def file from the symbol export list, so that
  1387. + # the compiled dll only exports the symbol export list.
  1388. + # Be careful not to strip the DATA tag left be newer dlltools.
  1389. + export_symbols_cmds="$ltdll_cmds"'
  1390. + $DLLTOOL --export-all --exclude-symbols '$dll_exclude_symbols' --output-def $output_objdir/$soname-def '$ltdll_obj'$libobjs $convenience~
  1391. + sed -e "1,/EXPORTS/d" -e "s/ @ [[0-9]]*//" -e "s/ *;.*$//" < $output_objdir/$soname-def > $export_symbols'
  1392. +
  1393. + # If the export-symbols file already is a .def file (1st line
  1394. + # is EXPORTS), use it as is.
  1395. + # If DATA tags from a recent dlltool are present, honour them!
  1396. + archive_expsym_cmds='if test "x`sed 1q $export_symbols`" = xEXPORTS; then
  1397. + cp $export_symbols $output_objdir/$soname-def;
  1398. + else
  1399. + echo EXPORTS > $output_objdir/$soname-def;
  1400. + _lt_hint=1;
  1401. + cat $export_symbols | while read symbol; do
  1402. + set dummy \$symbol;
  1403. + case \[$]# in
  1404. + 2) echo " \[$]2 @ \$_lt_hint ; " >> $output_objdir/$soname-def;;
  1405. + 4) echo " \[$]2 \[$]3 \[$]4 ; " >> $output_objdir/$soname-def; _lt_hint=`expr \$_lt_hint - 1`;;
  1406. + *) echo " \[$]2 @ \$_lt_hint \[$]3 ; " >> $output_objdir/$soname-def;;
  1407. + esac;
  1408. + _lt_hint=`expr 1 + \$_lt_hint`;
  1409. + done;
  1410. + fi~
  1411. + '"$ltdll_cmds"'
  1412. + $CC -Wl,--base-file,$output_objdir/$soname-base '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
  1413. + $DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp~
  1414. + $CC -Wl,--base-file,$output_objdir/$soname-base $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags~
  1415. + $DLLTOOL --as=$AS --dllname $soname --exclude-symbols '$dll_exclude_symbols' --def $output_objdir/$soname-def --base-file $output_objdir/$soname-base --output-exp $output_objdir/$soname-exp --output-lib $output_objdir/$libname.dll.a~
  1416. + $CC $output_objdir/$soname-exp '$lt_cv_cc_dll_switch' -Wl,-e,'$dll_entry' -o $output_objdir/$soname '$ltdll_obj'$libobjs $deplibs $compiler_flags'
  1417. + ;;
  1418. +
  1419. + netbsd*)
  1420. + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  1421. + archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
  1422. + wlarc=
  1423. + else
  1424. + archive_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  1425. + archive_expsym_cmds='$CC -shared -nodefaultlibs $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  1426. fi
  1427. - rm -f pf_packet-test* core core.pf_packet-test
  1428. ;;
  1429. - esac])
  1430. -])
  1431. -dnl
  1432. -dnl Looks for a previous libnet version and attempts to determine which verion
  1433. -dnl it is. Version 0.8 was the first version that actually knew internally
  1434. -dnl what version it was.
  1435. -dnl
  1436. -dnl usage:
  1437. -dnl
  1438. -dnl AC_LIBNET_CHECK_LIBNET_VERSION
  1439. -dnl
  1440. -dnl results:
  1441. -dnl
  1442. -dnl
  1443. -dnl
  1444. + solaris* | sysv5*)
  1445. + if $LD -v 2>&1 | egrep 'BFD 2\.8' > /dev/null; then
  1446. + ld_shlibs=no
  1447. + cat <<EOF 1>&2
  1448. -AC_DEFUN(AC_LIBNET_CHECK_LIBNET_VER,
  1449. -[
  1450. - AC_CHECK_LIB(net, libnet_build_ip, AC_MSG_CHECKING(version) \
  1451. +*** Warning: The releases 2.8.* of the GNU linker cannot reliably
  1452. +*** create shared libraries on Solaris systems. Therefore, libtool
  1453. +*** is disabling shared libraries support. We urge you to upgrade GNU
  1454. +*** binutils to release 2.9.1 or newer. Another option is to modify
  1455. +*** your PATH or compiler configuration so that the native linker is
  1456. +*** used, and then restart.
  1457. +
  1458. +EOF
  1459. + elif $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
  1460. + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  1461. + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  1462. + else
  1463. + ld_shlibs=no
  1464. + fi
  1465. + ;;
  1466. +
  1467. + sunos4*)
  1468. + archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  1469. + wlarc=
  1470. + hardcode_direct=yes
  1471. + hardcode_shlibpath_var=no
  1472. + ;;
  1473. + *)
  1474. + if $LD --help 2>&1 | egrep ': supported targets:.* elf' > /dev/null; then
  1475. + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
  1476. + archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
  1477. + else
  1478. + ld_shlibs=no
  1479. + fi
  1480. + ;;
  1481. + esac
  1482. +
  1483. + if test "$ld_shlibs" = yes; then
  1484. + runpath_var=LD_RUN_PATH
  1485. + hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
  1486. + export_dynamic_flag_spec='${wl}--export-dynamic'
  1487. + case $host_os in
  1488. + cygwin* | mingw* | pw32*)
  1489. + # dlltool doesn't understand --whole-archive et. al.
  1490. + whole_archive_flag_spec=
  1491. + ;;
  1492. + *)
  1493. + # ancient GNU ld didn't support --whole-archive et. al.
  1494. + if $LD --help 2>&1 | egrep 'no-whole-archive' > /dev/null; then
  1495. + whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
  1496. + else
  1497. + whole_archive_flag_spec=
  1498. + fi
  1499. + ;;
  1500. + esac
  1501. + fi
  1502. +else
  1503. + # PORTME fill in a description of your system's linker (not GNU ld)
  1504. + case $host_os in
  1505. + aix3*)
  1506. + allow_undefined_flag=unsupported
  1507. + always_export_symbols=yes
  1508. + archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
  1509. + # Note: this linker hardcodes the directories in LIBPATH if there
  1510. + # are no directories specified by -L.
  1511. + hardcode_minus_L=yes
  1512. + if test "$GCC" = yes && test -z "$link_static_flag"; then
  1513. + # Neither direct hardcoding nor static linking is supported with a
  1514. + # broken collect2.
  1515. + hardcode_direct=unsupported
  1516. + fi
  1517. + ;;
  1518. +
  1519. + aix4* | aix5*)
  1520. + if test "$host_cpu" = ia64; then
  1521. + # On IA64, the linker does run time linking by default, so we don't
  1522. + # have to do anything special.
  1523. + aix_use_runtimelinking=no
  1524. + exp_sym_flag='-Bexport'
  1525. + no_entry_flag=""
  1526. + else
  1527. + aix_use_runtimelinking=no
  1528. +
  1529. + # Test if we are trying to use run time linking or normal
  1530. + # AIX style linking. If -brtl is somewhere in LDFLAGS, we
  1531. + # need to do runtime linking.
  1532. + case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
  1533. + for ld_flag in $LDFLAGS; do
  1534. + case $ld_flag in
  1535. + *-brtl*)
  1536. + aix_use_runtimelinking=yes
  1537. + break
  1538. + ;;
  1539. + esac
  1540. + done
  1541. + esac
  1542. +
  1543. + exp_sym_flag='-bexport'
  1544. + no_entry_flag='-bnoentry'
  1545. + fi
  1546. +
  1547. + # When large executables or shared objects are built, AIX ld can
  1548. + # have problems creating the table of contents. If linking a library
  1549. + # or program results in "error TOC overflow" add -mminimal-toc to
  1550. + # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
  1551. + # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
  1552. +
  1553. + hardcode_direct=yes
  1554. + archive_cmds=''
  1555. + hardcode_libdir_separator=':'
  1556. + if test "$GCC" = yes; then
  1557. + case $host_os in aix4.[[012]]|aix4.[[012]].*)
  1558. + collect2name=`${CC} -print-prog-name=collect2`
  1559. + if test -f "$collect2name" && \
  1560. + strings "$collect2name" | grep resolve_lib_name >/dev/null
  1561. + then
  1562. + # We have reworked collect2
  1563. + hardcode_direct=yes
  1564. + else
  1565. + # We have old collect2
  1566. + hardcode_direct=unsupported
  1567. + # It fails to find uninstalled libraries when the uninstalled
  1568. + # path is not listed in the libpath. Setting hardcode_minus_L
  1569. + # to unsupported forces relinking
  1570. + hardcode_minus_L=yes
  1571. + hardcode_libdir_flag_spec='-L$libdir'
  1572. + hardcode_libdir_separator=
  1573. + fi
  1574. + esac
  1575. +
  1576. + shared_flag='-shared'
  1577. + else
  1578. + # not using gcc
  1579. + if test "$host_cpu" = ia64; then
  1580. + shared_flag='${wl}-G'
  1581. + else
  1582. + if test "$aix_use_runtimelinking" = yes; then
  1583. + shared_flag='${wl}-G'
  1584. + else
  1585. + shared_flag='${wl}-bM:SRE'
  1586. + fi
  1587. + fi
  1588. + fi
  1589. +
  1590. + # It seems that -bexpall can do strange things, so it is better to
  1591. + # generate a list of symbols to export.
  1592. + always_export_symbols=yes
  1593. + if test "$aix_use_runtimelinking" = yes; then
  1594. + # Warning - without using the other runtime loading flags (-brtl),
  1595. + # -berok will link without error, but may produce a broken library.
  1596. + allow_undefined_flag='-berok'
  1597. + hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:/usr/lib:/lib'
  1598. + archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
  1599. + else
  1600. + if test "$host_cpu" = ia64; then
  1601. + hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
  1602. + allow_undefined_flag="-z nodefs"
  1603. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname ${wl}-h$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
  1604. + else
  1605. + hardcode_libdir_flag_spec='${wl}-bnolibpath ${wl}-blibpath:$libdir:/usr/lib:/lib'
  1606. + # Warning - without using the other run time loading flags,
  1607. + # -berok will link without error, but may produce a broken library.
  1608. + allow_undefined_flag='${wl}-berok'
  1609. + # This is a bit strange, but is similar to how AIX traditionally builds
  1610. + # it's shared libraries.
  1611. + archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"' ~$AR -crlo $output_objdir/$libname$release.a $output_objdir/$soname'
  1612. + fi
  1613. + fi
  1614. + ;;
  1615. +
  1616. + amigaos*)
  1617. + archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
  1618. + hardcode_libdir_flag_spec='-L$libdir'
  1619. + hardcode_minus_L=yes
  1620. + # see comment about different semantics on the GNU ld section
  1621. + ld_shlibs=no
  1622. + ;;
  1623. +
  1624. + cygwin* | mingw* | pw32*)
  1625. + # When not using gcc, we currently assume that we are using
  1626. + # Microsoft Visual C++.
  1627. + # hardcode_libdir_flag_spec is actually meaningless, as there is
  1628. + # no search path for DLLs.
  1629. + hardcode_libdir_flag_spec=' '
  1630. + allow_undefined_flag=unsupported
  1631. + # Tell ltmain to make .lib files, not .a files.
  1632. + libext=lib
  1633. + # FIXME: Setting linknames here is a bad hack.
  1634. + archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | sed -e '\''s/ -lc$//'\''` -link -dll~linknames='
  1635. + # The linker will automatically build a .lib file if we build a DLL.
  1636. + old_archive_from_new_cmds='true'
  1637. + # FIXME: Should let the user specify the lib program.
  1638. + old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
  1639. + fix_srcfile_path='`cygpath -w "$srcfile"`'
  1640. + ;;
  1641. +
  1642. + darwin* | rhapsody*)
  1643. + case "$host_os" in
  1644. + rhapsody* | darwin1.[[012]])
  1645. + allow_undefined_flag='-undefined suppress'
  1646. + ;;
  1647. + *) # Darwin 1.3 on
  1648. + allow_undefined_flag='-flat_namespace -undefined suppress'
  1649. + ;;
  1650. + esac
  1651. + # FIXME: Relying on posixy $() will cause problems for
  1652. + # cross-compilation, but unfortunately the echo tests do not
  1653. + # yet detect zsh echo's removal of \ escapes. Also zsh mangles
  1654. + # `"' quotes if we put them in here... so don't!
  1655. + archive_cmds='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs && $CC $(test .$module = .yes && echo -bundle || echo -dynamiclib) $allow_undefined_flag -o $lib ${lib}-master.o $deplibs$linker_flags $(test .$module != .yes && echo -install_name $rpath/$soname $verstring)'
  1656. + # We need to add '_' to the symbols in $export_symbols first
  1657. + #archive_expsym_cmds="$archive_cmds"' && strip -s $export_symbols'
  1658. + hardcode_direct=yes
  1659. + hardcode_shlibpath_var=no
  1660. + whole_archive_flag_spec='-all_load $convenience'
  1661. + ;;
  1662. +
  1663. + freebsd1*)
  1664. + ld_shlibs=no
  1665. + ;;
  1666. +
  1667. + # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
  1668. + # support. Future versions do this automatically, but an explicit c++rt0.o
  1669. + # does not break anything, and helps significantly (at the cost of a little
  1670. + # extra space).
  1671. + freebsd2.2*)
  1672. + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
  1673. + hardcode_libdir_flag_spec='-R$libdir'
  1674. + hardcode_direct=yes
  1675. + hardcode_shlibpath_var=no
  1676. + ;;
  1677. +
  1678. + # Unfortunately, older versions of FreeBSD 2 do not have this feature.
  1679. + freebsd2*)
  1680. + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  1681. + hardcode_direct=yes
  1682. + hardcode_minus_L=yes
  1683. + hardcode_shlibpath_var=no
  1684. + ;;
  1685. +
  1686. + # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
  1687. + freebsd*)
  1688. + archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
  1689. + hardcode_libdir_flag_spec='-R$libdir'
  1690. + hardcode_direct=yes
  1691. + hardcode_shlibpath_var=no
  1692. + ;;
  1693. +
  1694. + hpux9* | hpux10* | hpux11*)
  1695. + case $host_os in
  1696. + hpux9*) archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' ;;
  1697. + *) archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' ;;
  1698. + esac
  1699. + hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
  1700. + hardcode_libdir_separator=:
  1701. + hardcode_direct=yes
  1702. + hardcode_minus_L=yes # Not in the search PATH, but as the default
  1703. + # location of the library.
  1704. + export_dynamic_flag_spec='${wl}-E'
  1705. + ;;
  1706. +
  1707. + irix5* | irix6* | nonstopux*)
  1708. + if test "$GCC" = yes; then
  1709. + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  1710. + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  1711. + else
  1712. + archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  1713. + hardcode_libdir_flag_spec='-rpath $libdir'
  1714. + fi
  1715. + hardcode_libdir_separator=:
  1716. + link_all_deplibs=yes
  1717. + ;;
  1718. +
  1719. + netbsd*)
  1720. + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  1721. + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
  1722. + else
  1723. + archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
  1724. + fi
  1725. + hardcode_libdir_flag_spec='-R$libdir'
  1726. + hardcode_direct=yes
  1727. + hardcode_shlibpath_var=no
  1728. + ;;
  1729. +
  1730. + newsos6)
  1731. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1732. + hardcode_direct=yes
  1733. + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  1734. + hardcode_libdir_separator=:
  1735. + hardcode_shlibpath_var=no
  1736. + ;;
  1737. +
  1738. + openbsd*)
  1739. + hardcode_direct=yes
  1740. + hardcode_shlibpath_var=no
  1741. + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  1742. + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  1743. + hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
  1744. + export_dynamic_flag_spec='${wl}-E'
  1745. + else
  1746. + case "$host_os" in
  1747. + openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
  1748. + archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
  1749. + hardcode_libdir_flag_spec='-R$libdir'
  1750. + ;;
  1751. + *)
  1752. + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
  1753. + hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
  1754. + ;;
  1755. + esac
  1756. + fi
  1757. + ;;
  1758. +
  1759. + os2*)
  1760. + hardcode_libdir_flag_spec='-L$libdir'
  1761. + hardcode_minus_L=yes
  1762. + allow_undefined_flag=unsupported
  1763. + archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
  1764. + old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
  1765. + ;;
  1766. +
  1767. + osf3*)
  1768. + if test "$GCC" = yes; then
  1769. + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
  1770. + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  1771. + else
  1772. + allow_undefined_flag=' -expect_unresolved \*'
  1773. + archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  1774. + fi
  1775. + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  1776. + hardcode_libdir_separator=:
  1777. + ;;
  1778. +
  1779. + osf4* | osf5*) # as osf3* with the addition of -msym flag
  1780. + if test "$GCC" = yes; then
  1781. + allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
  1782. + archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
  1783. + hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
  1784. + else
  1785. + allow_undefined_flag=' -expect_unresolved \*'
  1786. + archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
  1787. + archive_expsym_cmds='for i in `cat $export_symbols`; do printf "-exported_symbol " >> $lib.exp; echo "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
  1788. + $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${objdir}/so_locations -o $lib~$rm $lib.exp'
  1789. +
  1790. + #Both c and cxx compiler support -rpath directly
  1791. + hardcode_libdir_flag_spec='-rpath $libdir'
  1792. + fi
  1793. + hardcode_libdir_separator=:
  1794. + ;;
  1795. +
  1796. + sco3.2v5*)
  1797. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1798. + hardcode_shlibpath_var=no
  1799. + runpath_var=LD_RUN_PATH
  1800. + hardcode_runpath_var=yes
  1801. + export_dynamic_flag_spec='${wl}-Bexport'
  1802. + ;;
  1803. +
  1804. + solaris*)
  1805. + # gcc --version < 3.0 without binutils cannot create self contained
  1806. + # shared libraries reliably, requiring libgcc.a to resolve some of
  1807. + # the object symbols generated in some cases. Libraries that use
  1808. + # assert need libgcc.a to resolve __eprintf, for example. Linking
  1809. + # a copy of libgcc.a into every shared library to guarantee resolving
  1810. + # such symbols causes other problems: According to Tim Van Holder
  1811. + # <tim.van.holder@pandora.be>, C++ libraries end up with a separate
  1812. + # (to the application) exception stack for one thing.
  1813. + no_undefined_flag=' -z defs'
  1814. + if test "$GCC" = yes; then
  1815. + case `$CC --version 2>/dev/null` in
  1816. + [[12]].*)
  1817. + cat <<EOF 1>&2
  1818. +
  1819. +*** Warning: Releases of GCC earlier than version 3.0 cannot reliably
  1820. +*** create self contained shared libraries on Solaris systems, without
  1821. +*** introducing a dependency on libgcc.a. Therefore, libtool is disabling
  1822. +*** -no-undefined support, which will at least allow you to build shared
  1823. +*** libraries. However, you may find that when you link such libraries
  1824. +*** into an application without using GCC, you have to manually add
  1825. +*** \`gcc --print-libgcc-file-name\` to the link command. We urge you to
  1826. +*** upgrade to a newer version of GCC. Another option is to rebuild your
  1827. +*** current GCC to use the GNU linker from GNU binutils 2.9.1 or newer.
  1828. +
  1829. +EOF
  1830. + no_undefined_flag=
  1831. + ;;
  1832. + esac
  1833. + fi
  1834. + # $CC -shared without GNU ld will not create a library from C++
  1835. + # object files and a static libstdc++, better avoid it by now
  1836. + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1837. + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  1838. + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
  1839. + hardcode_libdir_flag_spec='-R$libdir'
  1840. + hardcode_shlibpath_var=no
  1841. + case $host_os in
  1842. + solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
  1843. + *) # Supported since Solaris 2.6 (maybe 2.5.1?)
  1844. + whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
  1845. + esac
  1846. + link_all_deplibs=yes
  1847. + ;;
  1848. +
  1849. + sunos4*)
  1850. + if test "x$host_vendor" = xsequent; then
  1851. + # Use $CC to link under sequent, because it throws in some extra .o
  1852. + # files that make .init and .fini sections work.
  1853. + archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
  1854. + else
  1855. + archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
  1856. + fi
  1857. + hardcode_libdir_flag_spec='-L$libdir'
  1858. + hardcode_direct=yes
  1859. + hardcode_minus_L=yes
  1860. + hardcode_shlibpath_var=no
  1861. + ;;
  1862. +
  1863. + sysv4)
  1864. + case $host_vendor in
  1865. + sni)
  1866. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1867. + hardcode_direct=yes # is this really true???
  1868. + ;;
  1869. + siemens)
  1870. + ## LD is ld it makes a PLAMLIB
  1871. + ## CC just makes a GrossModule.
  1872. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
  1873. + reload_cmds='$CC -r -o $output$reload_objs'
  1874. + hardcode_direct=no
  1875. + ;;
  1876. + motorola)
  1877. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1878. + hardcode_direct=no #Motorola manual says yes, but my tests say they lie
  1879. + ;;
  1880. + esac
  1881. + runpath_var='LD_RUN_PATH'
  1882. + hardcode_shlibpath_var=no
  1883. + ;;
  1884. +
  1885. + sysv4.3*)
  1886. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1887. + hardcode_shlibpath_var=no
  1888. + export_dynamic_flag_spec='-Bexport'
  1889. + ;;
  1890. +
  1891. + sysv5*)
  1892. + no_undefined_flag=' -z text'
  1893. + # $CC -shared without GNU ld will not create a library from C++
  1894. + # object files and a static libstdc++, better avoid it by now
  1895. + archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1896. + archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
  1897. + $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
  1898. + hardcode_libdir_flag_spec=
  1899. + hardcode_shlibpath_var=no
  1900. + runpath_var='LD_RUN_PATH'
  1901. + ;;
  1902. +
  1903. + uts4*)
  1904. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1905. + hardcode_libdir_flag_spec='-L$libdir'
  1906. + hardcode_shlibpath_var=no
  1907. + ;;
  1908. +
  1909. + dgux*)
  1910. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1911. + hardcode_libdir_flag_spec='-L$libdir'
  1912. + hardcode_shlibpath_var=no
  1913. + ;;
  1914. +
  1915. + sysv4*MP*)
  1916. + if test -d /usr/nec; then
  1917. + archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
  1918. + hardcode_shlibpath_var=no
  1919. + runpath_var=LD_RUN_PATH
  1920. + hardcode_runpath_var=yes
  1921. + ld_shlibs=yes
  1922. + fi
  1923. + ;;
  1924. +
  1925. + sysv4.2uw2*)
  1926. + archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
  1927. + hardcode_direct=yes
  1928. + hardcode_minus_L=no
  1929. + hardcode_shlibpath_var=no
  1930. + hardcode_runpath_var=yes
  1931. + runpath_var=LD_RUN_PATH
  1932. + ;;
  1933. +
  1934. + sysv5uw7* | unixware7*)
  1935. + no_undefined_flag='${wl}-z ${wl}text'
  1936. + if test "$GCC" = yes; then
  1937. + archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  1938. + else
  1939. + archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
  1940. + fi
  1941. + runpath_var='LD_RUN_PATH'
  1942. + hardcode_shlibpath_var=no
  1943. + ;;
  1944. +
  1945. + *)
  1946. + ld_shlibs=no
  1947. + ;;
  1948. + esac
  1949. +fi
  1950. +AC_MSG_RESULT([$ld_shlibs])
  1951. +test "$ld_shlibs" = no && can_build_shared=no
  1952. +
  1953. +# Check hardcoding attributes.
  1954. +AC_MSG_CHECKING([how to hardcode library paths into programs])
  1955. +hardcode_action=
  1956. +if test -n "$hardcode_libdir_flag_spec" || \
  1957. + test -n "$runpath_var"; then
  1958. +
  1959. + # We can hardcode non-existant directories.
  1960. + if test "$hardcode_direct" != no &&
  1961. + # If the only mechanism to avoid hardcoding is shlibpath_var, we
  1962. + # have to relink, otherwise we might link with an installed library
  1963. + # when we should be linking with a yet-to-be-installed one
  1964. + ## test "$hardcode_shlibpath_var" != no &&
  1965. + test "$hardcode_minus_L" != no; then
  1966. + # Linking always hardcodes the temporary library directory.
  1967. + hardcode_action=relink
  1968. + else
  1969. + # We can link without hardcoding, and we can hardcode nonexisting dirs.
  1970. + hardcode_action=immediate
  1971. + fi
  1972. +else
  1973. + # We cannot hardcode anything, or else we can only hardcode existing
  1974. + # directories.
  1975. + hardcode_action=unsupported
  1976. +fi
  1977. +AC_MSG_RESULT([$hardcode_action])
  1978. +
  1979. +striplib=
  1980. +old_striplib=
  1981. +AC_MSG_CHECKING([whether stripping libraries is possible])
  1982. +if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
  1983. + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
  1984. + test -z "$striplib" && striplib="$STRIP --strip-unneeded"
  1985. + AC_MSG_RESULT([yes])
  1986. +else
  1987. + AC_MSG_RESULT([no])
  1988. +fi
  1989. +
  1990. +reload_cmds='$LD$reload_flag -o $output$reload_objs'
  1991. +test -z "$deplibs_check_method" && deplibs_check_method=unknown
  1992. +
  1993. +# PORTME Fill in your ld.so characteristics
  1994. +AC_MSG_CHECKING([dynamic linker characteristics])
  1995. +library_names_spec=
  1996. +libname_spec='lib$name'
  1997. +soname_spec=
  1998. +postinstall_cmds=
  1999. +postuninstall_cmds=
  2000. +finish_cmds=
  2001. +finish_eval=
  2002. +shlibpath_var=
  2003. +shlibpath_overrides_runpath=unknown
  2004. +version_type=none
  2005. +dynamic_linker="$host_os ld.so"
  2006. +sys_lib_dlsearch_path_spec="/lib /usr/lib"
  2007. +sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
  2008. +
  2009. +case $host_os in
  2010. +aix3*)
  2011. + version_type=linux
  2012. + library_names_spec='${libname}${release}.so$versuffix $libname.a'
  2013. + shlibpath_var=LIBPATH
  2014. +
  2015. + # AIX has no versioning support, so we append a major version to the name.
  2016. + soname_spec='${libname}${release}.so$major'
  2017. + ;;
  2018. +
  2019. +aix4* | aix5*)
  2020. + version_type=linux
  2021. + need_lib_prefix=no
  2022. + need_version=no
  2023. + hardcode_into_libs=yes
  2024. + if test "$host_cpu" = ia64; then
  2025. + # AIX 5 supports IA64
  2026. + library_names_spec='${libname}${release}.so$major ${libname}${release}.so$versuffix $libname.so'
  2027. + shlibpath_var=LD_LIBRARY_PATH
  2028. + else
  2029. + # With GCC up to 2.95.x, collect2 would create an import file
  2030. + # for dependence libraries. The import file would start with
  2031. + # the line `#! .'. This would cause the generated library to
  2032. + # depend on `.', always an invalid library. This was fixed in
  2033. + # development snapshots of GCC prior to 3.0.
  2034. + case $host_os in
  2035. + aix4 | aix4.[[01]] | aix4.[[01]].*)
  2036. + if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
  2037. + echo ' yes '
  2038. + echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
  2039. + :
  2040. + else
  2041. + can_build_shared=no
  2042. + fi
  2043. + ;;
  2044. + esac
  2045. + # AIX (on Power*) has no versioning support, so currently we can
  2046. + # not hardcode correct soname into executable. Probably we can
  2047. + # add versioning support to collect2, so additional links can
  2048. + # be useful in future.
  2049. + if test "$aix_use_runtimelinking" = yes; then
  2050. + # If using run time linking (on AIX 4.2 or later) use lib<name>.so
  2051. + # instead of lib<name>.a to let people know that these are not
  2052. + # typical AIX shared libraries.
  2053. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2054. + else
  2055. + # We preserve .a as extension for shared libraries through AIX4.2
  2056. + # and later when we are not doing run time linking.
  2057. + library_names_spec='${libname}${release}.a $libname.a'
  2058. + soname_spec='${libname}${release}.so$major'
  2059. + fi
  2060. + shlibpath_var=LIBPATH
  2061. + fi
  2062. + hardcode_into_libs=yes
  2063. + ;;
  2064. +
  2065. +amigaos*)
  2066. + library_names_spec='$libname.ixlibrary $libname.a'
  2067. + # Create ${libname}_ixlibrary.a entries in /sys/libs.
  2068. + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "(cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a)"; (cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a) || exit 1; done'
  2069. + ;;
  2070. +
  2071. +beos*)
  2072. + library_names_spec='${libname}.so'
  2073. + dynamic_linker="$host_os ld.so"
  2074. + shlibpath_var=LIBRARY_PATH
  2075. + ;;
  2076. +
  2077. +bsdi4*)
  2078. + version_type=linux
  2079. + need_version=no
  2080. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2081. + soname_spec='${libname}${release}.so$major'
  2082. + finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
  2083. + shlibpath_var=LD_LIBRARY_PATH
  2084. + sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
  2085. + sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
  2086. + export_dynamic_flag_spec=-rdynamic
  2087. + # the default ld.so.conf also contains /usr/contrib/lib and
  2088. + # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
  2089. + # libtool to hard-code these into programs
  2090. + ;;
  2091. +
  2092. +cygwin* | mingw* | pw32*)
  2093. + version_type=windows
  2094. + need_version=no
  2095. + need_lib_prefix=no
  2096. + case $GCC,$host_os in
  2097. + yes,cygwin*)
  2098. + library_names_spec='$libname.dll.a'
  2099. + soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
  2100. + postinstall_cmds='dlpath=`bash 2>&1 -c '\''. $dir/${file}i;echo \$dlname'\''`~
  2101. + dldir=$destdir/`dirname \$dlpath`~
  2102. + test -d \$dldir || mkdir -p \$dldir~
  2103. + $install_prog .libs/$dlname \$dldir/$dlname'
  2104. + postuninstall_cmds='dldll=`bash 2>&1 -c '\''. $file; echo \$dlname'\''`~
  2105. + dlpath=$dir/\$dldll~
  2106. + $rm \$dlpath'
  2107. + ;;
  2108. + yes,mingw*)
  2109. + library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll'
  2110. + sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | sed -e "s/^libraries://" -e "s/;/ /g" -e "s,=/,/,g"`
  2111. + ;;
  2112. + yes,pw32*)
  2113. + library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | sed -e 's/[.]/-/g'`${versuffix}.dll'
  2114. + ;;
  2115. + *)
  2116. + library_names_spec='${libname}`echo ${release} | sed -e 's/[[.]]/-/g'`${versuffix}.dll $libname.lib'
  2117. + ;;
  2118. + esac
  2119. + dynamic_linker='Win32 ld.exe'
  2120. + # FIXME: first we should search . and the directory the executable is in
  2121. + shlibpath_var=PATH
  2122. + ;;
  2123. +
  2124. +darwin* | rhapsody*)
  2125. + dynamic_linker="$host_os dyld"
  2126. + version_type=darwin
  2127. + need_lib_prefix=no
  2128. + need_version=no
  2129. + # FIXME: Relying on posixy $() will cause problems for
  2130. + # cross-compilation, but unfortunately the echo tests do not
  2131. + # yet detect zsh echo's removal of \ escapes.
  2132. + library_names_spec='${libname}${release}${versuffix}.$(test .$module = .yes && echo so || echo dylib) ${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib) ${libname}.$(test .$module = .yes && echo so || echo dylib)'
  2133. + soname_spec='${libname}${release}${major}.$(test .$module = .yes && echo so || echo dylib)'
  2134. + shlibpath_overrides_runpath=yes
  2135. + shlibpath_var=DYLD_LIBRARY_PATH
  2136. + ;;
  2137. +
  2138. +freebsd1*)
  2139. + dynamic_linker=no
  2140. + ;;
  2141. +
  2142. +kfreebsd*-gnu*)
  2143. + version_type=linux
  2144. + need_lib_prefix=no
  2145. + need_version=no
  2146. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2147. + soname_spec='${libname}${release}.so$major'
  2148. + shlibpath_var=LD_LIBRARY_PATH
  2149. + shlibpath_overrides_runpath=no
  2150. + hardcode_into_libs=yes
  2151. + dynamic_linker='GNU/FreeBSD ld.so'
  2152. + ;;
  2153. +
  2154. +freebsd*)
  2155. + objformat=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
  2156. + version_type=freebsd-$objformat
  2157. + case $version_type in
  2158. + freebsd-elf*)
  2159. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so $libname.so'
  2160. + need_version=no
  2161. + need_lib_prefix=no
  2162. + ;;
  2163. + freebsd-*)
  2164. + library_names_spec='${libname}${release}.so$versuffix $libname.so$versuffix'
  2165. + need_version=yes
  2166. + ;;
  2167. + esac
  2168. + shlibpath_var=LD_LIBRARY_PATH
  2169. + case $host_os in
  2170. + freebsd2*)
  2171. + shlibpath_overrides_runpath=yes
  2172. + ;;
  2173. + *)
  2174. + shlibpath_overrides_runpath=no
  2175. + hardcode_into_libs=yes
  2176. + ;;
  2177. + esac
  2178. + ;;
  2179. +
  2180. +gnu*)
  2181. + version_type=linux
  2182. + need_lib_prefix=no
  2183. + need_version=no
  2184. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
  2185. + soname_spec='${libname}${release}.so$major'
  2186. + shlibpath_var=LD_LIBRARY_PATH
  2187. + hardcode_into_libs=yes
  2188. + ;;
  2189. +
  2190. +hpux9* | hpux10* | hpux11*)
  2191. + # Give a soname corresponding to the major version so that dld.sl refuses to
  2192. + # link against other versions.
  2193. + dynamic_linker="$host_os dld.sl"
  2194. + version_type=sunos
  2195. + need_lib_prefix=no
  2196. + need_version=no
  2197. + shlibpath_var=SHLIB_PATH
  2198. + shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
  2199. + library_names_spec='${libname}${release}.sl$versuffix ${libname}${release}.sl$major $libname.sl'
  2200. + soname_spec='${libname}${release}.sl$major'
  2201. + # HP-UX runs *really* slowly unless shared libraries are mode 555.
  2202. + postinstall_cmds='chmod 555 $lib'
  2203. + ;;
  2204. +
  2205. +irix5* | irix6* | nonstopux*)
  2206. + case $host_os in
  2207. + nonstopux*) version_type=nonstopux ;;
  2208. + *) version_type=irix ;;
  2209. + esac
  2210. + need_lib_prefix=no
  2211. + need_version=no
  2212. + soname_spec='${libname}${release}.so$major'
  2213. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so $libname.so'
  2214. + case $host_os in
  2215. + irix5* | nonstopux*)
  2216. + libsuff= shlibsuff=
  2217. + ;;
  2218. + *)
  2219. + case $LD in # libtool.m4 will add one of these switches to LD
  2220. + *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
  2221. + *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
  2222. + *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
  2223. + *) libsuff= shlibsuff= libmagic=never-match;;
  2224. + esac
  2225. + ;;
  2226. + esac
  2227. + shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
  2228. + shlibpath_overrides_runpath=no
  2229. + sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
  2230. + sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
  2231. + ;;
  2232. +
  2233. +# No shared lib support for Linux oldld, aout, or coff.
  2234. +linux-gnuoldld* | linux-gnuaout* | linux-gnucoff*)
  2235. + dynamic_linker=no
  2236. + ;;
  2237. +
  2238. +# This must be Linux ELF.
  2239. +linux-gnu*)
  2240. + version_type=linux
  2241. + need_lib_prefix=no
  2242. + need_version=no
  2243. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2244. + soname_spec='${libname}${release}.so$major'
  2245. + finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
  2246. + shlibpath_var=LD_LIBRARY_PATH
  2247. + shlibpath_overrides_runpath=no
  2248. + # This implies no fast_install, which is unacceptable.
  2249. + # Some rework will be needed to allow for fast_install
  2250. + # before this can be enabled.
  2251. + hardcode_into_libs=yes
  2252. +
  2253. + # We used to test for /lib/ld.so.1 and disable shared libraries on
  2254. + # powerpc, because MkLinux only supported shared libraries with the
  2255. + # GNU dynamic linker. Since this was broken with cross compilers,
  2256. + # most powerpc-linux boxes support dynamic linking these days and
  2257. + # people can always --disable-shared, the test was removed, and we
  2258. + # assume the GNU/Linux dynamic linker is in use.
  2259. + dynamic_linker='GNU/Linux ld.so'
  2260. + ;;
  2261. +
  2262. +netbsd*)
  2263. + version_type=sunos
  2264. + need_lib_prefix=no
  2265. + need_version=no
  2266. + if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
  2267. + library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
  2268. + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  2269. + dynamic_linker='NetBSD (a.out) ld.so'
  2270. + else
  2271. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major ${libname}${release}.so ${libname}.so'
  2272. + soname_spec='${libname}${release}.so$major'
  2273. + dynamic_linker='NetBSD ld.elf_so'
  2274. + fi
  2275. + shlibpath_var=LD_LIBRARY_PATH
  2276. + shlibpath_overrides_runpath=yes
  2277. + hardcode_into_libs=yes
  2278. + ;;
  2279. +
  2280. +newsos6)
  2281. + version_type=linux
  2282. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2283. + shlibpath_var=LD_LIBRARY_PATH
  2284. + shlibpath_overrides_runpath=yes
  2285. + ;;
  2286. +
  2287. +openbsd*)
  2288. + version_type=sunos
  2289. + need_lib_prefix=no
  2290. + need_version=no
  2291. + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  2292. + case "$host_os" in
  2293. + openbsd2.[[89]] | openbsd2.[[89]].*)
  2294. + shlibpath_overrides_runpath=no
  2295. + ;;
  2296. + *)
  2297. + shlibpath_overrides_runpath=yes
  2298. + ;;
  2299. + esac
  2300. + else
  2301. + shlibpath_overrides_runpath=yes
  2302. + fi
  2303. + library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
  2304. + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
  2305. + shlibpath_var=LD_LIBRARY_PATH
  2306. + ;;
  2307. +
  2308. +os2*)
  2309. + libname_spec='$name'
  2310. + need_lib_prefix=no
  2311. + library_names_spec='$libname.dll $libname.a'
  2312. + dynamic_linker='OS/2 ld.exe'
  2313. + shlibpath_var=LIBPATH
  2314. + ;;
  2315. +
  2316. +osf3* | osf4* | osf5*)
  2317. + version_type=osf
  2318. + need_version=no
  2319. + need_lib_prefix=no
  2320. + soname_spec='${libname}${release}.so$major'
  2321. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2322. + shlibpath_var=LD_LIBRARY_PATH
  2323. + sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
  2324. + sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
  2325. + hardcode_into_libs=yes
  2326. + ;;
  2327. +
  2328. +sco3.2v5*)
  2329. + version_type=osf
  2330. + soname_spec='${libname}${release}.so$major'
  2331. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2332. + shlibpath_var=LD_LIBRARY_PATH
  2333. + ;;
  2334. +
  2335. +solaris*)
  2336. + version_type=linux
  2337. + need_lib_prefix=no
  2338. + need_version=no
  2339. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2340. + soname_spec='${libname}${release}.so$major'
  2341. + shlibpath_var=LD_LIBRARY_PATH
  2342. + shlibpath_overrides_runpath=yes
  2343. + hardcode_into_libs=yes
  2344. + # ldd complains unless libraries are executable
  2345. + postinstall_cmds='chmod +x $lib'
  2346. + ;;
  2347. +
  2348. +sunos4*)
  2349. + version_type=sunos
  2350. + library_names_spec='${libname}${release}.so$versuffix ${libname}.so$versuffix'
  2351. + finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
  2352. + shlibpath_var=LD_LIBRARY_PATH
  2353. + shlibpath_overrides_runpath=yes
  2354. + if test "$with_gnu_ld" = yes; then
  2355. + need_lib_prefix=no
  2356. + fi
  2357. + need_version=yes
  2358. + ;;
  2359. +
  2360. +sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
  2361. + version_type=linux
  2362. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2363. + soname_spec='${libname}${release}.so$major'
  2364. + shlibpath_var=LD_LIBRARY_PATH
  2365. + case $host_vendor in
  2366. + sni)
  2367. + shlibpath_overrides_runpath=no
  2368. + need_lib_prefix=no
  2369. + export_dynamic_flag_spec='${wl}-Blargedynsym'
  2370. + runpath_var=LD_RUN_PATH
  2371. + ;;
  2372. + siemens)
  2373. + need_lib_prefix=no
  2374. + ;;
  2375. + motorola)
  2376. + need_lib_prefix=no
  2377. + need_version=no
  2378. + shlibpath_overrides_runpath=no
  2379. + sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
  2380. + ;;
  2381. + esac
  2382. + ;;
  2383. +
  2384. +uts4*)
  2385. + version_type=linux
  2386. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2387. + soname_spec='${libname}${release}.so$major'
  2388. + shlibpath_var=LD_LIBRARY_PATH
  2389. + ;;
  2390. +
  2391. +dgux*)
  2392. + version_type=linux
  2393. + need_lib_prefix=no
  2394. + need_version=no
  2395. + library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so$major $libname.so'
  2396. + soname_spec='${libname}${release}.so$major'
  2397. + shlibpath_var=LD_LIBRARY_PATH
  2398. + ;;
  2399. +
  2400. +sysv4*MP*)
  2401. + if test -d /usr/nec ;then
  2402. + version_type=linux
  2403. + library_names_spec='$libname.so.$versuffix $libname.so.$major $libname.so'
  2404. + soname_spec='$libname.so.$major'
  2405. + shlibpath_var=LD_LIBRARY_PATH
  2406. + fi
  2407. + ;;
  2408. +
  2409. +*)
  2410. + dynamic_linker=no
  2411. + ;;
  2412. +esac
  2413. +AC_MSG_RESULT([$dynamic_linker])
  2414. +test "$dynamic_linker" = no && can_build_shared=no
  2415. +
  2416. +# Report the final consequences.
  2417. +AC_MSG_CHECKING([if libtool supports shared libraries])
  2418. +AC_MSG_RESULT([$can_build_shared])
  2419. +
  2420. +AC_MSG_CHECKING([whether to build shared libraries])
  2421. +test "$can_build_shared" = "no" && enable_shared=no
  2422. +
  2423. +# On AIX, shared libraries and static libraries use the same namespace, and
  2424. +# are all built from PIC.
  2425. +case "$host_os" in
  2426. +aix3*)
  2427. + test "$enable_shared" = yes && enable_static=no
  2428. + if test -n "$RANLIB"; then
  2429. + archive_cmds="$archive_cmds~\$RANLIB \$lib"
  2430. + postinstall_cmds='$RANLIB $lib'
  2431. + fi
  2432. + ;;
  2433. +
  2434. +aix4*)
  2435. + if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
  2436. + test "$enable_shared" = yes && enable_static=no
  2437. + fi
  2438. + ;;
  2439. +esac
  2440. +AC_MSG_RESULT([$enable_shared])
  2441. +
  2442. +AC_MSG_CHECKING([whether to build static libraries])
  2443. +# Make sure either enable_shared or enable_static is yes.
  2444. +test "$enable_shared" = yes || enable_static=yes
  2445. +AC_MSG_RESULT([$enable_static])
  2446. +
  2447. +if test "$hardcode_action" = relink; then
  2448. + # Fast installation is not supported
  2449. + enable_fast_install=no
  2450. +elif test "$shlibpath_overrides_runpath" = yes ||
  2451. + test "$enable_shared" = no; then
  2452. + # Fast installation is not necessary
  2453. + enable_fast_install=needless
  2454. +fi
  2455. +
  2456. +variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
  2457. +if test "$GCC" = yes; then
  2458. + variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
  2459. +fi
  2460. +
  2461. +AC_LIBTOOL_DLOPEN_SELF
  2462. +
  2463. +if test "$enable_shared" = yes && test "$GCC" = yes; then
  2464. + case $archive_cmds in
  2465. + *'~'*)
  2466. + # FIXME: we may have to deal with multi-command sequences.
  2467. + ;;
  2468. + '$CC '*)
  2469. + # Test whether the compiler implicitly links with -lc since on some
  2470. + # systems, -lgcc has to come before -lc. If gcc already passes -lc
  2471. + # to ld, don't add -lc before -lgcc.
  2472. + AC_MSG_CHECKING([whether -lc should be explicitly linked in])
  2473. + AC_CACHE_VAL([lt_cv_archive_cmds_need_lc],
  2474. + [$rm conftest*
  2475. + echo 'static int dummy;' > conftest.$ac_ext
  2476. +
  2477. + if AC_TRY_EVAL(ac_compile); then
  2478. + soname=conftest
  2479. + lib=conftest
  2480. + libobjs=conftest.$ac_objext
  2481. + deplibs=
  2482. + wl=$lt_cv_prog_cc_wl
  2483. + compiler_flags=-v
  2484. + linker_flags=-v
  2485. + verstring=
  2486. + output_objdir=.
  2487. + libname=conftest
  2488. + save_allow_undefined_flag=$allow_undefined_flag
  2489. + allow_undefined_flag=
  2490. + if AC_TRY_EVAL(archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1)
  2491. + then
  2492. + lt_cv_archive_cmds_need_lc=no
  2493. + else
  2494. + lt_cv_archive_cmds_need_lc=yes
  2495. + fi
  2496. + allow_undefined_flag=$save_allow_undefined_flag
  2497. + else
  2498. + cat conftest.err 1>&5
  2499. + fi])
  2500. + AC_MSG_RESULT([$lt_cv_archive_cmds_need_lc])
  2501. + ;;
  2502. + esac
  2503. +fi
  2504. +need_lc=${lt_cv_archive_cmds_need_lc-yes}
  2505. +
  2506. +# The second clause should only fire when bootstrapping the
  2507. +# libtool distribution, otherwise you forgot to ship ltmain.sh
  2508. +# with your package, and you will get complaints that there are
  2509. +# no rules to generate ltmain.sh.
  2510. +if test -f "$ltmain"; then
  2511. + :
  2512. +else
  2513. + # If there is no Makefile yet, we rely on a make rule to execute
  2514. + # `config.status --recheck' to rerun these tests and create the
  2515. + # libtool script then.
  2516. + ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
  2517. + if test -f "$ltmain_in"; then
  2518. + test -f Makefile && make "$ltmain"
  2519. + fi
  2520. +fi
  2521. +
  2522. +if test -f "$ltmain"; then
  2523. + trap "$rm \"${ofile}T\"; exit 1" 1 2 15
  2524. + $rm -f "${ofile}T"
  2525. +
  2526. + echo creating $ofile
  2527. +
  2528. + # Now quote all the things that may contain metacharacters while being
  2529. + # careful not to overquote the AC_SUBSTed values. We take copies of the
  2530. + # variables and quote the copies for generation of the libtool script.
  2531. + for var in echo old_CC old_CFLAGS SED \
  2532. + AR AR_FLAGS CC LD LN_S NM SHELL STRIP \
  2533. + reload_flag reload_cmds wl \
  2534. + pic_flag link_static_flag no_builtin_flag export_dynamic_flag_spec \
  2535. + thread_safe_flag_spec whole_archive_flag_spec libname_spec \
  2536. + library_names_spec soname_spec \
  2537. + RANLIB old_archive_cmds old_archive_from_new_cmds old_postinstall_cmds \
  2538. + old_postuninstall_cmds archive_cmds archive_expsym_cmds postinstall_cmds \
  2539. + postuninstall_cmds extract_expsyms_cmds old_archive_from_expsyms_cmds \
  2540. + old_striplib striplib file_magic_cmd export_symbols_cmds \
  2541. + deplibs_check_method allow_undefined_flag no_undefined_flag \
  2542. + finish_cmds finish_eval global_symbol_pipe global_symbol_to_cdecl \
  2543. + global_symbol_to_c_name_address \
  2544. + hardcode_libdir_flag_spec hardcode_libdir_separator \
  2545. + sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
  2546. + compiler_c_o compiler_o_lo need_locks exclude_expsyms include_expsyms; do
  2547. +
  2548. + case $var in
  2549. + reload_cmds | old_archive_cmds | old_archive_from_new_cmds | \
  2550. + old_postinstall_cmds | old_postuninstall_cmds | \
  2551. + export_symbols_cmds | archive_cmds | archive_expsym_cmds | \
  2552. + extract_expsyms_cmds | old_archive_from_expsyms_cmds | \
  2553. + postinstall_cmds | postuninstall_cmds | \
  2554. + finish_cmds | sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
  2555. + # Double-quote double-evaled strings.
  2556. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
  2557. + ;;
  2558. + *)
  2559. + eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
  2560. + ;;
  2561. + esac
  2562. + done
  2563. +
  2564. + cat <<__EOF__ > "${ofile}T"
  2565. +#! $SHELL
  2566. +
  2567. +# `$echo "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
  2568. +# Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
  2569. +# NOTE: Changes made to this file will be lost: look at ltmain.sh.
  2570. +#
  2571. +# Copyright (C) 1996-2000 Free Software Foundation, Inc.
  2572. +# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
  2573. +#
  2574. +# This program is free software; you can redistribute it and/or modify
  2575. +# it under the terms of the GNU General Public License as published by
  2576. +# the Free Software Foundation; either version 2 of the License, or
  2577. +# (at your option) any later version.
  2578. +#
  2579. +# This program is distributed in the hope that it will be useful, but
  2580. +# WITHOUT ANY WARRANTY; without even the implied warranty of
  2581. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  2582. +# General Public License for more details.
  2583. +#
  2584. +# You should have received a copy of the GNU General Public License
  2585. +# along with this program; if not, write to the Free Software
  2586. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  2587. +#
  2588. +# As a special exception to the GNU General Public License, if you
  2589. +# distribute this file as part of a program that contains a
  2590. +# configuration script generated by Autoconf, you may include it under
  2591. +# the same distribution terms that you use for the rest of that program.
  2592. +
  2593. +# A sed that does not truncate output.
  2594. +SED=$lt_SED
  2595. +
  2596. +# Sed that helps us avoid accidentally triggering echo(1) options like -n.
  2597. +Xsed="${SED} -e s/^X//"
  2598. +
  2599. +# The HP-UX ksh and POSIX shell print the target directory to stdout
  2600. +# if CDPATH is set.
  2601. +if test "X\${CDPATH+set}" = Xset; then CDPATH=:; export CDPATH; fi
  2602. +
  2603. +# ### BEGIN LIBTOOL CONFIG
  2604. +
  2605. +# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
  2606. +
  2607. +# Shell to use when invoking shell scripts.
  2608. +SHELL=$lt_SHELL
  2609. +
  2610. +# Whether or not to build shared libraries.
  2611. +build_libtool_libs=$enable_shared
  2612. +
  2613. +# Whether or not to build static libraries.
  2614. +build_old_libs=$enable_static
  2615. +
  2616. +# Whether or not to add -lc for building shared libraries.
  2617. +build_libtool_need_lc=$need_lc
  2618. +
  2619. +# Whether or not to optimize for fast installation.
  2620. +fast_install=$enable_fast_install
  2621. +
  2622. +# The host system.
  2623. +host_alias=$host_alias
  2624. +host=$host
  2625. +
  2626. +# An echo program that does not interpret backslashes.
  2627. +echo=$lt_echo
  2628. +
  2629. +# The archiver.
  2630. +AR=$lt_AR
  2631. +AR_FLAGS=$lt_AR_FLAGS
  2632. +
  2633. +# The default C compiler.
  2634. +CC=$lt_CC
  2635. +
  2636. +# Is the compiler the GNU C compiler?
  2637. +with_gcc=$GCC
  2638. +
  2639. +# The linker used to build libraries.
  2640. +LD=$lt_LD
  2641. +
  2642. +# Whether we need hard or soft links.
  2643. +LN_S=$lt_LN_S
  2644. +
  2645. +# A BSD-compatible nm program.
  2646. +NM=$lt_NM
  2647. +
  2648. +# A symbol stripping program
  2649. +STRIP=$lt_STRIP
  2650. +
  2651. +# Used to examine libraries when file_magic_cmd begins "file"
  2652. +MAGIC_CMD=$MAGIC_CMD
  2653. +
  2654. +# Used on cygwin: DLL creation program.
  2655. +DLLTOOL="$DLLTOOL"
  2656. +
  2657. +# Used on cygwin: object dumper.
  2658. +OBJDUMP="$OBJDUMP"
  2659. +
  2660. +# Used on cygwin: assembler.
  2661. +AS="$AS"
  2662. +
  2663. +# The name of the directory that contains temporary libtool files.
  2664. +objdir=$objdir
  2665. +
  2666. +# How to create reloadable object files.
  2667. +reload_flag=$lt_reload_flag
  2668. +reload_cmds=$lt_reload_cmds
  2669. +
  2670. +# How to pass a linker flag through the compiler.
  2671. +wl=$lt_wl
  2672. +
  2673. +# Object file suffix (normally "o").
  2674. +objext="$ac_objext"
  2675. +
  2676. +# Old archive suffix (normally "a").
  2677. +libext="$libext"
  2678. +
  2679. +# Executable file suffix (normally "").
  2680. +exeext="$exeext"
  2681. +
  2682. +# Additional compiler flags for building library objects.
  2683. +pic_flag=$lt_pic_flag
  2684. +pic_mode=$pic_mode
  2685. +
  2686. +# Does compiler simultaneously support -c and -o options?
  2687. +compiler_c_o=$lt_compiler_c_o
  2688. +
  2689. +# Can we write directly to a .lo ?
  2690. +compiler_o_lo=$lt_compiler_o_lo
  2691. +
  2692. +# Must we lock files when doing compilation ?
  2693. +need_locks=$lt_need_locks
  2694. +
  2695. +# Do we need the lib prefix for modules?
  2696. +need_lib_prefix=$need_lib_prefix
  2697. +
  2698. +# Do we need a version for libraries?
  2699. +need_version=$need_version
  2700. +
  2701. +# Whether dlopen is supported.
  2702. +dlopen_support=$enable_dlopen
  2703. +
  2704. +# Whether dlopen of programs is supported.
  2705. +dlopen_self=$enable_dlopen_self
  2706. +
  2707. +# Whether dlopen of statically linked programs is supported.
  2708. +dlopen_self_static=$enable_dlopen_self_static
  2709. +
  2710. +# Compiler flag to prevent dynamic linking.
  2711. +link_static_flag=$lt_link_static_flag
  2712. +
  2713. +# Compiler flag to turn off builtin functions.
  2714. +no_builtin_flag=$lt_no_builtin_flag
  2715. +
  2716. +# Compiler flag to allow reflexive dlopens.
  2717. +export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
  2718. +
  2719. +# Compiler flag to generate shared objects directly from archives.
  2720. +whole_archive_flag_spec=$lt_whole_archive_flag_spec
  2721. +
  2722. +# Compiler flag to generate thread-safe objects.
  2723. +thread_safe_flag_spec=$lt_thread_safe_flag_spec
  2724. +
  2725. +# Library versioning type.
  2726. +version_type=$version_type
  2727. +
  2728. +# Format of library name prefix.
  2729. +libname_spec=$lt_libname_spec
  2730. +
  2731. +# List of archive names. First name is the real one, the rest are links.
  2732. +# The last name is the one that the linker finds with -lNAME.
  2733. +library_names_spec=$lt_library_names_spec
  2734. +
  2735. +# The coded name of the library, if different from the real name.
  2736. +soname_spec=$lt_soname_spec
  2737. +
  2738. +# Commands used to build and install an old-style archive.
  2739. +RANLIB=$lt_RANLIB
  2740. +old_archive_cmds=$lt_old_archive_cmds
  2741. +old_postinstall_cmds=$lt_old_postinstall_cmds
  2742. +old_postuninstall_cmds=$lt_old_postuninstall_cmds
  2743. +
  2744. +# Create an old-style archive from a shared archive.
  2745. +old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
  2746. +
  2747. +# Create a temporary old-style archive to link instead of a shared archive.
  2748. +old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
  2749. +
  2750. +# Commands used to build and install a shared archive.
  2751. +archive_cmds=$lt_archive_cmds
  2752. +archive_expsym_cmds=$lt_archive_expsym_cmds
  2753. +postinstall_cmds=$lt_postinstall_cmds
  2754. +postuninstall_cmds=$lt_postuninstall_cmds
  2755. +
  2756. +# Commands to strip libraries.
  2757. +old_striplib=$lt_old_striplib
  2758. +striplib=$lt_striplib
  2759. +
  2760. +# Method to check whether dependent libraries are shared objects.
  2761. +deplibs_check_method=$lt_deplibs_check_method
  2762. +
  2763. +# Command to use when deplibs_check_method == file_magic.
  2764. +file_magic_cmd=$lt_file_magic_cmd
  2765. +
  2766. +# Flag that allows shared libraries with undefined symbols to be built.
  2767. +allow_undefined_flag=$lt_allow_undefined_flag
  2768. +
  2769. +# Flag that forces no undefined symbols.
  2770. +no_undefined_flag=$lt_no_undefined_flag
  2771. +
  2772. +# Commands used to finish a libtool library installation in a directory.
  2773. +finish_cmds=$lt_finish_cmds
  2774. +
  2775. +# Same as above, but a single script fragment to be evaled but not shown.
  2776. +finish_eval=$lt_finish_eval
  2777. +
  2778. +# Take the output of nm and produce a listing of raw symbols and C names.
  2779. +global_symbol_pipe=$lt_global_symbol_pipe
  2780. +
  2781. +# Transform the output of nm in a proper C declaration
  2782. +global_symbol_to_cdecl=$lt_global_symbol_to_cdecl
  2783. +
  2784. +# Transform the output of nm in a C name address pair
  2785. +global_symbol_to_c_name_address=$lt_global_symbol_to_c_name_address
  2786. +
  2787. +# This is the shared library runtime path variable.
  2788. +runpath_var=$runpath_var
  2789. +
  2790. +# This is the shared library path variable.
  2791. +shlibpath_var=$shlibpath_var
  2792. +
  2793. +# Is shlibpath searched before the hard-coded library search path?
  2794. +shlibpath_overrides_runpath=$shlibpath_overrides_runpath
  2795. +
  2796. +# How to hardcode a shared library path into an executable.
  2797. +hardcode_action=$hardcode_action
  2798. +
  2799. +# Whether we should hardcode library paths into libraries.
  2800. +hardcode_into_libs=$hardcode_into_libs
  2801. +
  2802. +# Flag to hardcode \$libdir into a binary during linking.
  2803. +# This must work even if \$libdir does not exist.
  2804. +hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
  2805. +
  2806. +# Whether we need a single -rpath flag with a separated argument.
  2807. +hardcode_libdir_separator=$lt_hardcode_libdir_separator
  2808. +
  2809. +# Set to yes if using DIR/libNAME.so during linking hardcodes DIR into the
  2810. +# resulting binary.
  2811. +hardcode_direct=$hardcode_direct
  2812. +
  2813. +# Set to yes if using the -LDIR flag during linking hardcodes DIR into the
  2814. +# resulting binary.
  2815. +hardcode_minus_L=$hardcode_minus_L
  2816. +
  2817. +# Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
  2818. +# the resulting binary.
  2819. +hardcode_shlibpath_var=$hardcode_shlibpath_var
  2820. +
  2821. +# Variables whose values should be saved in libtool wrapper scripts and
  2822. +# restored at relink time.
  2823. +variables_saved_for_relink="$variables_saved_for_relink"
  2824. +
  2825. +# Whether libtool must link a program against all its dependency libraries.
  2826. +link_all_deplibs=$link_all_deplibs
  2827. +
  2828. +# Compile-time system search path for libraries
  2829. +sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
  2830. +
  2831. +# Run-time system search path for libraries
  2832. +sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
  2833. +
  2834. +# Fix the shell variable \$srcfile for the compiler.
  2835. +fix_srcfile_path="$fix_srcfile_path"
  2836. +
  2837. +# Set to yes if exported symbols are required.
  2838. +always_export_symbols=$always_export_symbols
  2839. +
  2840. +# The commands to list exported symbols.
  2841. +export_symbols_cmds=$lt_export_symbols_cmds
  2842. +
  2843. +# The commands to extract the exported symbol list from a shared archive.
  2844. +extract_expsyms_cmds=$lt_extract_expsyms_cmds
  2845. +
  2846. +# Symbols that should not be listed in the preloaded symbols.
  2847. +exclude_expsyms=$lt_exclude_expsyms
  2848. +
  2849. +# Symbols that must always be exported.
  2850. +include_expsyms=$lt_include_expsyms
  2851. +
  2852. +# ### END LIBTOOL CONFIG
  2853. +
  2854. +__EOF__
  2855. +
  2856. + case $host_os in
  2857. + aix3*)
  2858. + cat <<\EOF >> "${ofile}T"
  2859. +
  2860. +# AIX sometimes has problems with the GCC collect2 program. For some
  2861. +# reason, if we set the COLLECT_NAMES environment variable, the problems
  2862. +# vanish in a puff of smoke.
  2863. +if test "X${COLLECT_NAMES+set}" != Xset; then
  2864. + COLLECT_NAMES=
  2865. + export COLLECT_NAMES
  2866. +fi
  2867. +EOF
  2868. + ;;
  2869. + esac
  2870. +
  2871. + case $host_os in
  2872. + cygwin* | mingw* | pw32* | os2*)
  2873. + cat <<'EOF' >> "${ofile}T"
  2874. + # This is a source program that is used to create dlls on Windows
  2875. + # Don't remove nor modify the starting and closing comments
  2876. +# /* ltdll.c starts here */
  2877. +# #define WIN32_LEAN_AND_MEAN
  2878. +# #include <windows.h>
  2879. +# #undef WIN32_LEAN_AND_MEAN
  2880. +# #include <stdio.h>
  2881. +#
  2882. +# #ifndef __CYGWIN__
  2883. +# # ifdef __CYGWIN32__
  2884. +# # define __CYGWIN__ __CYGWIN32__
  2885. +# # endif
  2886. +# #endif
  2887. +#
  2888. +# #ifdef __cplusplus
  2889. +# extern "C" {
  2890. +# #endif
  2891. +# BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved);
  2892. +# #ifdef __cplusplus
  2893. +# }
  2894. +# #endif
  2895. +#
  2896. +# #ifdef __CYGWIN__
  2897. +# #include <cygwin/cygwin_dll.h>
  2898. +# DECLARE_CYGWIN_DLL( DllMain );
  2899. +# #endif
  2900. +# HINSTANCE __hDllInstance_base;
  2901. +#
  2902. +# BOOL APIENTRY
  2903. +# DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved)
  2904. +# {
  2905. +# __hDllInstance_base = hInst;
  2906. +# return TRUE;
  2907. +# }
  2908. +# /* ltdll.c ends here */
  2909. + # This is a source program that is used to create import libraries
  2910. + # on Windows for dlls which lack them. Don't remove nor modify the
  2911. + # starting and closing comments
  2912. +# /* impgen.c starts here */
  2913. +# /* Copyright (C) 1999-2000 Free Software Foundation, Inc.
  2914. +#
  2915. +# This file is part of GNU libtool.
  2916. +#
  2917. +# This program is free software; you can redistribute it and/or modify
  2918. +# it under the terms of the GNU General Public License as published by
  2919. +# the Free Software Foundation; either version 2 of the License, or
  2920. +# (at your option) any later version.
  2921. +#
  2922. +# This program is distributed in the hope that it will be useful,
  2923. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  2924. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  2925. +# GNU General Public License for more details.
  2926. +#
  2927. +# You should have received a copy of the GNU General Public License
  2928. +# along with this program; if not, write to the Free Software
  2929. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  2930. +# */
  2931. +#
  2932. +# #include <stdio.h> /* for printf() */
  2933. +# #include <unistd.h> /* for open(), lseek(), read() */
  2934. +# #include <fcntl.h> /* for O_RDONLY, O_BINARY */
  2935. +# #include <string.h> /* for strdup() */
  2936. +#
  2937. +# /* O_BINARY isn't required (or even defined sometimes) under Unix */
  2938. +# #ifndef O_BINARY
  2939. +# #define O_BINARY 0
  2940. +# #endif
  2941. +#
  2942. +# static unsigned int
  2943. +# pe_get16 (fd, offset)
  2944. +# int fd;
  2945. +# int offset;
  2946. +# {
  2947. +# unsigned char b[2];
  2948. +# lseek (fd, offset, SEEK_SET);
  2949. +# read (fd, b, 2);
  2950. +# return b[0] + (b[1]<<8);
  2951. +# }
  2952. +#
  2953. +# static unsigned int
  2954. +# pe_get32 (fd, offset)
  2955. +# int fd;
  2956. +# int offset;
  2957. +# {
  2958. +# unsigned char b[4];
  2959. +# lseek (fd, offset, SEEK_SET);
  2960. +# read (fd, b, 4);
  2961. +# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
  2962. +# }
  2963. +#
  2964. +# static unsigned int
  2965. +# pe_as32 (ptr)
  2966. +# void *ptr;
  2967. +# {
  2968. +# unsigned char *b = ptr;
  2969. +# return b[0] + (b[1]<<8) + (b[2]<<16) + (b[3]<<24);
  2970. +# }
  2971. +#
  2972. +# int
  2973. +# main (argc, argv)
  2974. +# int argc;
  2975. +# char *argv[];
  2976. +# {
  2977. +# int dll;
  2978. +# unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
  2979. +# unsigned long export_rva, export_size, nsections, secptr, expptr;
  2980. +# unsigned long name_rvas, nexp;
  2981. +# unsigned char *expdata, *erva;
  2982. +# char *filename, *dll_name;
  2983. +#
  2984. +# filename = argv[1];
  2985. +#
  2986. +# dll = open(filename, O_RDONLY|O_BINARY);
  2987. +# if (dll < 1)
  2988. +# return 1;
  2989. +#
  2990. +# dll_name = filename;
  2991. +#
  2992. +# for (i=0; filename[i]; i++)
  2993. +# if (filename[i] == '/' || filename[i] == '\\' || filename[i] == ':')
  2994. +# dll_name = filename + i +1;
  2995. +#
  2996. +# pe_header_offset = pe_get32 (dll, 0x3c);
  2997. +# opthdr_ofs = pe_header_offset + 4 + 20;
  2998. +# num_entries = pe_get32 (dll, opthdr_ofs + 92);
  2999. +#
  3000. +# if (num_entries < 1) /* no exports */
  3001. +# return 1;
  3002. +#
  3003. +# export_rva = pe_get32 (dll, opthdr_ofs + 96);
  3004. +# export_size = pe_get32 (dll, opthdr_ofs + 100);
  3005. +# nsections = pe_get16 (dll, pe_header_offset + 4 +2);
  3006. +# secptr = (pe_header_offset + 4 + 20 +
  3007. +# pe_get16 (dll, pe_header_offset + 4 + 16));
  3008. +#
  3009. +# expptr = 0;
  3010. +# for (i = 0; i < nsections; i++)
  3011. +# {
  3012. +# char sname[8];
  3013. +# unsigned long secptr1 = secptr + 40 * i;
  3014. +# unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
  3015. +# unsigned long vsize = pe_get32 (dll, secptr1 + 16);
  3016. +# unsigned long fptr = pe_get32 (dll, secptr1 + 20);
  3017. +# lseek(dll, secptr1, SEEK_SET);
  3018. +# read(dll, sname, 8);
  3019. +# if (vaddr <= export_rva && vaddr+vsize > export_rva)
  3020. +# {
  3021. +# expptr = fptr + (export_rva - vaddr);
  3022. +# if (export_rva + export_size > vaddr + vsize)
  3023. +# export_size = vsize - (export_rva - vaddr);
  3024. +# break;
  3025. +# }
  3026. +# }
  3027. +#
  3028. +# expdata = (unsigned char*)malloc(export_size);
  3029. +# lseek (dll, expptr, SEEK_SET);
  3030. +# read (dll, expdata, export_size);
  3031. +# erva = expdata - export_rva;
  3032. +#
  3033. +# nexp = pe_as32 (expdata+24);
  3034. +# name_rvas = pe_as32 (expdata+32);
  3035. +#
  3036. +# printf ("EXPORTS\n");
  3037. +# for (i = 0; i<nexp; i++)
  3038. +# {
  3039. +# unsigned long name_rva = pe_as32 (erva+name_rvas+i*4);
  3040. +# printf ("\t%s @ %ld ;\n", erva+name_rva, 1+ i);
  3041. +# }
  3042. +#
  3043. +# return 0;
  3044. +# }
  3045. +# /* impgen.c ends here */
  3046. +
  3047. +EOF
  3048. + ;;
  3049. + esac
  3050. +
  3051. + # We use sed instead of cat because bash on DJGPP gets confused if
  3052. + # if finds mixed CR/LF and LF-only lines. Since sed operates in
  3053. + # text mode, it properly converts lines to CR/LF. This bash problem
  3054. + # is reportedly fixed, but why not run on old versions too?
  3055. + sed '$q' "$ltmain" >> "${ofile}T" || (rm -f "${ofile}T"; exit 1)
  3056. +
  3057. + mv -f "${ofile}T" "$ofile" || \
  3058. + (rm -f "$ofile" && cp "${ofile}T" "$ofile" && rm -f "${ofile}T")
  3059. + chmod +x "$ofile"
  3060. +fi
  3061. +
  3062. +])# _LT_AC_LTCONFIG_HACK
  3063. +
  3064. +# AC_LIBTOOL_DLOPEN - enable checks for dlopen support
  3065. +AC_DEFUN([AC_LIBTOOL_DLOPEN], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])])
  3066. +
  3067. +# AC_LIBTOOL_WIN32_DLL - declare package support for building win32 dll's
  3068. +AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_BEFORE([$0], [AC_LIBTOOL_SETUP])])
  3069. +
  3070. +# AC_ENABLE_SHARED - implement the --enable-shared flag
  3071. +# Usage: AC_ENABLE_SHARED[(DEFAULT)]
  3072. +# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
  3073. +# `yes'.
  3074. +AC_DEFUN([AC_ENABLE_SHARED],
  3075. +[define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl
  3076. +AC_ARG_ENABLE(shared,
  3077. changequote(<<, >>)dnl
  3078. - if [[ ! -f $LIB_PREFIX/libnet.a ]] ; then
  3079. +<< --enable-shared[=PKGS] build shared libraries [default=>>AC_ENABLE_SHARED_DEFAULT],
  3080. changequote([, ])dnl
  3081. - AC_MSG_RESULT($LIB_PREFIX/libnet.a doesn't exist)
  3082. - AC_MSG_RESULT(previous libnet install lives elsewhere, you should probably find it)
  3083. - else
  3084. - __LIBNET_VERSION=`strings $LIB_PREFIX/libnet.a | grep "libnet version"\
  3085. - | cut -f3 -d" "`;\
  3086. - if test -z "$__LIBNET_VERSION"; then
  3087. - AC_MSG_RESULT(<0.8)
  3088. - else
  3089. - AC_MSG_RESULT($__LIBNET_VERSION)
  3090. - fi
  3091. - fi\
  3092. - )
  3093. +[p=${PACKAGE-default}
  3094. +case $enableval in
  3095. +yes) enable_shared=yes ;;
  3096. +no) enable_shared=no ;;
  3097. +*)
  3098. + enable_shared=no
  3099. + # Look at the argument we got. We use all the common list separators.
  3100. + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
  3101. + for pkg in $enableval; do
  3102. + if test "X$pkg" = "X$p"; then
  3103. + enable_shared=yes
  3104. + fi
  3105. + done
  3106. + IFS="$ac_save_ifs"
  3107. + ;;
  3108. +esac],
  3109. +enable_shared=AC_ENABLE_SHARED_DEFAULT)dnl
  3110. ])
  3111. +# AC_DISABLE_SHARED - set the default shared flag to --disable-shared
  3112. +AC_DEFUN([AC_DISABLE_SHARED],
  3113. +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3114. +AC_ENABLE_SHARED(no)])
  3115. -dnl
  3116. -dnl Checks to see if this linux kernel uses ip_sum or ip_csum
  3117. -dnl (Pulled from queso)
  3118. -dnl
  3119. -dnl usage:
  3120. -dnl
  3121. -dnl AC_LIBNET_CHECK_IP_CSUM
  3122. -dnl
  3123. -dnl results:
  3124. -dnl
  3125. -dnl HAVE_STRUCT_IP_CSUM (DEFINED)
  3126. -dnl
  3127. +# AC_ENABLE_STATIC - implement the --enable-static flag
  3128. +# Usage: AC_ENABLE_STATIC[(DEFAULT)]
  3129. +# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
  3130. +# `yes'.
  3131. +AC_DEFUN([AC_ENABLE_STATIC],
  3132. +[define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl
  3133. +AC_ARG_ENABLE(static,
  3134. +changequote(<<, >>)dnl
  3135. +<< --enable-static[=PKGS] build static libraries [default=>>AC_ENABLE_STATIC_DEFAULT],
  3136. +changequote([, ])dnl
  3137. +[p=${PACKAGE-default}
  3138. +case $enableval in
  3139. +yes) enable_static=yes ;;
  3140. +no) enable_static=no ;;
  3141. +*)
  3142. + enable_static=no
  3143. + # Look at the argument we got. We use all the common list separators.
  3144. + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
  3145. + for pkg in $enableval; do
  3146. + if test "X$pkg" = "X$p"; then
  3147. + enable_static=yes
  3148. + fi
  3149. + done
  3150. + IFS="$ac_save_ifs"
  3151. + ;;
  3152. +esac],
  3153. +enable_static=AC_ENABLE_STATIC_DEFAULT)dnl
  3154. +])
  3155. -AC_DEFUN(AC_LIBNET_CHECK_IP_CSUM,
  3156. -[
  3157. - AC_MSG_CHECKING([struct ip contains ip_csum])
  3158. - AC_TRY_COMPILE([
  3159. - #define __BSD_SOURCE
  3160. - #define _BSD_SOURCE
  3161. - #include <sys/types.h>
  3162. - #include <netinet/in.h>
  3163. - #include <netinet/in_systm.h>
  3164. - #include <netinet/ip.h>],
  3165. - [
  3166. - struct ip ip;
  3167. - ip.ip_csum = 0;
  3168. - ],
  3169. - [AC_MSG_RESULT(yes);
  3170. - AC_DEFINE(HAVE_STRUCT_IP_CSUM)],
  3171. - [AC_MSG_RESULT(no);
  3172. - ])
  3173. +# AC_DISABLE_STATIC - set the default static flag to --disable-static
  3174. +AC_DEFUN([AC_DISABLE_STATIC],
  3175. +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3176. +AC_ENABLE_STATIC(no)])
  3177. +
  3178. +
  3179. +# AC_ENABLE_FAST_INSTALL - implement the --enable-fast-install flag
  3180. +# Usage: AC_ENABLE_FAST_INSTALL[(DEFAULT)]
  3181. +# Where DEFAULT is either `yes' or `no'. If omitted, it defaults to
  3182. +# `yes'.
  3183. +AC_DEFUN([AC_ENABLE_FAST_INSTALL],
  3184. +[define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl
  3185. +AC_ARG_ENABLE(fast-install,
  3186. +changequote(<<, >>)dnl
  3187. +<< --enable-fast-install[=PKGS] optimize for fast installation [default=>>AC_ENABLE_FAST_INSTALL_DEFAULT],
  3188. +changequote([, ])dnl
  3189. +[p=${PACKAGE-default}
  3190. +case $enableval in
  3191. +yes) enable_fast_install=yes ;;
  3192. +no) enable_fast_install=no ;;
  3193. +*)
  3194. + enable_fast_install=no
  3195. + # Look at the argument we got. We use all the common list separators.
  3196. + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:,"
  3197. + for pkg in $enableval; do
  3198. + if test "X$pkg" = "X$p"; then
  3199. + enable_fast_install=yes
  3200. + fi
  3201. + done
  3202. + IFS="$ac_save_ifs"
  3203. + ;;
  3204. +esac],
  3205. +enable_fast_install=AC_ENABLE_FAST_INSTALL_DEFAULT)dnl
  3206. ])
  3207. -dnl
  3208. -dnl Checks to see if unaligned memory accesses fail
  3209. -dnl (Pulled from libpcap)
  3210. -dnl
  3211. -dnl usage:
  3212. -dnl
  3213. -dnl AC_LBL_UNALIGNED_ACCESS
  3214. -dnl
  3215. -dnl results:
  3216. -dnl
  3217. -dnl LBL_ALIGN (DEFINED)
  3218. -dnl
  3219. +# AC_DISABLE_FAST_INSTALL - set the default to --disable-fast-install
  3220. +AC_DEFUN([AC_DISABLE_FAST_INSTALL],
  3221. +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3222. +AC_ENABLE_FAST_INSTALL(no)])
  3223. -AC_DEFUN(AC_LBL_UNALIGNED_ACCESS,
  3224. - [AC_MSG_CHECKING(if unaligned accesses fail)
  3225. - AC_CACHE_VAL(ac_cv_lbl_unaligned_fail,
  3226. - [case "$target_cpu" in
  3227. +# AC_LIBTOOL_PICMODE - implement the --with-pic flag
  3228. +# Usage: AC_LIBTOOL_PICMODE[(MODE)]
  3229. +# Where MODE is either `yes' or `no'. If omitted, it defaults to
  3230. +# `both'.
  3231. +AC_DEFUN([AC_LIBTOOL_PICMODE],
  3232. +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3233. +pic_mode=ifelse($#,1,$1,default)])
  3234. - alpha|hp*|mips|sparc)
  3235. - ac_cv_lbl_unaligned_fail=yes
  3236. - ;;
  3237. - *)
  3238. - cat >conftest.c <<EOF
  3239. -# include <sys/types.h>
  3240. -# include <sys/wait.h>
  3241. -# include <stdio.h>
  3242. - unsigned char a[[5]] = { 1, 2, 3, 4, 5 };
  3243. - main()
  3244. - {
  3245. - unsigned int i;
  3246. - pid_t pid;
  3247. - int status;
  3248. - /* avoid "core dumped" message */
  3249. - pid = fork();
  3250. - if (pid < 0)
  3251. - {
  3252. - exit(2);
  3253. - }
  3254. - if (pid > 0)
  3255. - {
  3256. - /* parent */
  3257. - pid = waitpid(pid, &status, 0);
  3258. - if (pid < 0)
  3259. - {
  3260. - exit(3);
  3261. - }
  3262. - exit(!WIFEXITED(status));
  3263. - }
  3264. - /* child */
  3265. - i = *(unsigned int *)&a[[1]];
  3266. - printf("%d\n", i);
  3267. - exit(0);
  3268. - }
  3269. +# AC_PATH_TOOL_PREFIX - find a file program which can recognise shared library
  3270. +AC_DEFUN([AC_PATH_TOOL_PREFIX],
  3271. +[AC_MSG_CHECKING([for $1])
  3272. +AC_CACHE_VAL(lt_cv_path_MAGIC_CMD,
  3273. +[case $MAGIC_CMD in
  3274. + /*)
  3275. + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
  3276. + ;;
  3277. + ?:/*)
  3278. + lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a dos path.
  3279. + ;;
  3280. + *)
  3281. + ac_save_MAGIC_CMD="$MAGIC_CMD"
  3282. + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
  3283. +dnl $ac_dummy forces splitting on constant user-supplied paths.
  3284. +dnl POSIX.2 word splitting is done only on the output of word expansions,
  3285. +dnl not every word. This closes a longstanding sh security hole.
  3286. + ac_dummy="ifelse([$2], , $PATH, [$2])"
  3287. + for ac_dir in $ac_dummy; do
  3288. + test -z "$ac_dir" && ac_dir=.
  3289. + if test -f $ac_dir/$1; then
  3290. + lt_cv_path_MAGIC_CMD="$ac_dir/$1"
  3291. + if test -n "$file_magic_test_file"; then
  3292. + case $deplibs_check_method in
  3293. + "file_magic "*)
  3294. + file_magic_regex="`expr \"$deplibs_check_method\" : \"file_magic \(.*\)\"`"
  3295. + MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  3296. + if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
  3297. + egrep "$file_magic_regex" > /dev/null; then
  3298. + :
  3299. + else
  3300. + cat <<EOF 1>&2
  3301. +
  3302. +*** Warning: the command libtool uses to detect shared libraries,
  3303. +*** $file_magic_cmd, produces output that libtool cannot recognize.
  3304. +*** The result is that libtool may fail to recognize shared libraries
  3305. +*** as such. This will affect the creation of libtool libraries that
  3306. +*** depend on shared libraries, but programs linked with such libtool
  3307. +*** libraries will work regardless of this problem. Nevertheless, you
  3308. +*** may want to report the problem to your system manager and/or to
  3309. +*** bug-libtool@gnu.org
  3310. +
  3311. EOF
  3312. - ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS \
  3313. - conftest.c $LIBS > /dev/null 2>&1
  3314. - # Oopz 4.3 BSD doesn't have this. Sorry.
  3315. - if test ! -x conftest ; then
  3316. - dnl failed to compile for some reason
  3317. - ac_cv_lbl_unaligned_fail=yes
  3318. - else
  3319. - ./conftest > conftest.out
  3320. - if test ! -s conftest.out ; then
  3321. - ac_cv_lbl_unaligned_fail=yes
  3322. - else
  3323. - ac_cv_lbl_unaligned_fail=no
  3324. - fi
  3325. - fi
  3326. - rm -f conftest* core core.conftest
  3327. - ;;
  3328. - esac])
  3329. - AC_MSG_RESULT($ac_cv_lbl_unaligned_fail)
  3330. - if test $ac_cv_lbl_unaligned_fail = yes ; then
  3331. - AC_DEFINE(LBL_ALIGN)
  3332. + fi ;;
  3333. + esac
  3334. + fi
  3335. + break
  3336. fi
  3337. + done
  3338. + IFS="$ac_save_ifs"
  3339. + MAGIC_CMD="$ac_save_MAGIC_CMD"
  3340. + ;;
  3341. +esac])
  3342. +MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
  3343. +if test -n "$MAGIC_CMD"; then
  3344. + AC_MSG_RESULT($MAGIC_CMD)
  3345. +else
  3346. + AC_MSG_RESULT(no)
  3347. +fi
  3348. ])
  3349. -dnl
  3350. -dnl Checks endianess
  3351. -dnl
  3352. -dnl usage:
  3353. -dnl
  3354. -dnl AC_LIBNET_ENDIAN_CHECK
  3355. -dnl
  3356. -dnl results:
  3357. -dnl
  3358. -dnl LIBNET_BIG_ENDIAN = 1 or
  3359. -dnl LIBNET_LIL_ENDIAN = 1
  3360. -dnl
  3361. +# AC_PATH_MAGIC - find a file program which can recognise a shared library
  3362. +AC_DEFUN([AC_PATH_MAGIC],
  3363. +[AC_REQUIRE([AC_CHECK_TOOL_PREFIX])dnl
  3364. +AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin:$PATH)
  3365. +if test -z "$lt_cv_path_MAGIC_CMD"; then
  3366. + if test -n "$ac_tool_prefix"; then
  3367. + AC_PATH_TOOL_PREFIX(file, /usr/bin:$PATH)
  3368. + else
  3369. + MAGIC_CMD=:
  3370. + fi
  3371. +fi
  3372. +])
  3373. -AC_DEFUN(AC_LIBNET_ENDIAN_CHECK,
  3374. - [AC_MSG_CHECKING(machine endianess)
  3375. - cat > conftest.c << EOF
  3376. -# include <stdio.h>
  3377. -# include <stdlib.h>
  3378. +# AC_PROG_LD - find the path to the GNU or non-GNU linker
  3379. +AC_DEFUN([AC_PROG_LD],
  3380. +[AC_ARG_WITH(gnu-ld,
  3381. +[ --with-gnu-ld assume the C compiler uses GNU ld [default=no]],
  3382. +test "$withval" = no || with_gnu_ld=yes, with_gnu_ld=no)
  3383. +AC_REQUIRE([AC_PROG_CC])dnl
  3384. +AC_REQUIRE([AC_CANONICAL_HOST])dnl
  3385. +AC_REQUIRE([AC_CANONICAL_BUILD])dnl
  3386. +AC_REQUIRE([_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR])dnl
  3387. +ac_prog=ld
  3388. +if test "$GCC" = yes; then
  3389. + # Check if gcc -print-prog-name=ld gives a path.
  3390. + AC_MSG_CHECKING([for ld used by GCC])
  3391. + case $host in
  3392. + *-*-mingw*)
  3393. + # gcc leaves a trailing carriage return which upsets mingw
  3394. + ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
  3395. + *)
  3396. + ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
  3397. + esac
  3398. + case $ac_prog in
  3399. + # Accept absolute paths.
  3400. + [[\\/]]* | [[A-Za-z]]:[[\\/]]*)
  3401. + re_direlt='/[[^/]][[^/]]*/\.\./'
  3402. + # Canonicalize the path of ld
  3403. + ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
  3404. + while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
  3405. + ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
  3406. + done
  3407. + test -z "$LD" && LD="$ac_prog"
  3408. + ;;
  3409. + "")
  3410. + # If it fails, then pretend we aren't using GCC.
  3411. + ac_prog=ld
  3412. + ;;
  3413. + *)
  3414. + # If it is relative, then search for the first ld in PATH.
  3415. + with_gnu_ld=unknown
  3416. + ;;
  3417. + esac
  3418. +elif test "$with_gnu_ld" = yes; then
  3419. + AC_MSG_CHECKING([for GNU ld])
  3420. +else
  3421. + AC_MSG_CHECKING([for non-GNU ld])
  3422. +fi
  3423. +AC_CACHE_VAL(lt_cv_path_LD,
  3424. +[if test -z "$LD"; then
  3425. + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  3426. + for ac_dir in $PATH; do
  3427. + test -z "$ac_dir" && ac_dir=.
  3428. + if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
  3429. + lt_cv_path_LD="$ac_dir/$ac_prog"
  3430. + # Check to see if the program is GNU ld. I'd rather use --version,
  3431. + # but apparently some GNU ld's only accept -v.
  3432. + # Break only if it was the GNU/non-GNU ld that we prefer.
  3433. + if "$lt_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
  3434. + test "$with_gnu_ld" != no && break
  3435. + else
  3436. + test "$with_gnu_ld" != yes && break
  3437. + fi
  3438. + fi
  3439. + done
  3440. + IFS="$ac_save_ifs"
  3441. +else
  3442. + lt_cv_path_LD="$LD" # Let the user override the test with a path.
  3443. +fi])
  3444. +LD="$lt_cv_path_LD"
  3445. +if test -n "$LD"; then
  3446. + AC_MSG_RESULT($LD)
  3447. +else
  3448. + AC_MSG_RESULT(no)
  3449. +fi
  3450. +test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH])
  3451. +AC_PROG_LD_GNU
  3452. +])
  3453. - int main()
  3454. - {
  3455. - union
  3456. - {
  3457. - short s;
  3458. - char c[[sizeof(short)]];
  3459. - } un;
  3460. +# AC_PROG_LD_GNU -
  3461. +AC_DEFUN([AC_PROG_LD_GNU],
  3462. +[AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld,
  3463. +[# I'd rather use --version here, but apparently some GNU ld's only accept -v.
  3464. +if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
  3465. + lt_cv_prog_gnu_ld=yes
  3466. +else
  3467. + lt_cv_prog_gnu_ld=no
  3468. +fi])
  3469. +with_gnu_ld=$lt_cv_prog_gnu_ld
  3470. +])
  3471. - un.s = 0x0102;
  3472. - if (sizeof (short) == 2)
  3473. - {
  3474. - if (un.c [[0]] == 1 && un.c [[1]] == 2)
  3475. - {
  3476. - printf("B\n");
  3477. - }
  3478. - else
  3479. - {
  3480. - if (un.c [[0]] == 2 && un.c [[1]] == 1)
  3481. - {
  3482. - printf("L\n");
  3483. - }
  3484. - }
  3485. - }
  3486. - else
  3487. - {
  3488. - printf("?\n");
  3489. - }
  3490. - return (EXIT_SUCCESS);
  3491. - }
  3492. -EOF
  3493. - ${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.c $LIBS > /dev/null 2>&1
  3494. - # Oopz 4.3 BSD doesn't have this. Sorry.
  3495. - if test ! -x conftest ; then
  3496. -dnl failed to compile for some reason
  3497. - ac_cv_libnet_endianess=unknown
  3498. - else
  3499. - ./conftest > conftest.out
  3500. - result=`cat conftest.out`
  3501. - if test $result = "B"; then
  3502. - ac_cv_libnet_endianess=big
  3503. - elif test $result = "L"; then
  3504. - ac_cv_libnet_endianess=lil
  3505. - else
  3506. - ac_cv_libnet_endianess=unknown
  3507. - fi
  3508. - fi
  3509. - rm -f conftest* core core.conftest
  3510. +# AC_PROG_LD_RELOAD_FLAG - find reload flag for linker
  3511. +# -- PORTME Some linkers may need a different reload flag.
  3512. +AC_DEFUN([AC_PROG_LD_RELOAD_FLAG],
  3513. +[AC_CACHE_CHECK([for $LD option to reload object files], lt_cv_ld_reload_flag,
  3514. +[lt_cv_ld_reload_flag='-r'])
  3515. +reload_flag=$lt_cv_ld_reload_flag
  3516. +test -n "$reload_flag" && reload_flag=" $reload_flag"
  3517. +])
  3518. - AC_MSG_RESULT($ac_cv_libnet_endianess)
  3519. +# AC_DEPLIBS_CHECK_METHOD - how to check for library dependencies
  3520. +# -- PORTME fill in with the dynamic library characteristics
  3521. +AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
  3522. +[AC_CACHE_CHECK([how to recognise dependent libraries],
  3523. +lt_cv_deplibs_check_method,
  3524. +[lt_cv_file_magic_cmd='$MAGIC_CMD'
  3525. +lt_cv_file_magic_test_file=
  3526. +lt_cv_deplibs_check_method='unknown'
  3527. +# Need to set the preceding variable on all platforms that support
  3528. +# interlibrary dependencies.
  3529. +# 'none' -- dependencies not supported.
  3530. +# `unknown' -- same as none, but documents that we really don't know.
  3531. +# 'pass_all' -- all dependencies passed with no checks.
  3532. +# 'test_compile' -- check by making test program.
  3533. +# 'file_magic [[regex]]' -- check by looking for files in library path
  3534. +# which responds to the $file_magic_cmd with a given egrep regex.
  3535. +# If you have `file' or equivalent on your system and you're not sure
  3536. +# whether `pass_all' will *always* work, you probably want this one.
  3537. - if test $ac_cv_libnet_endianess = big ; then
  3538. - AC_DEFINE(LIBNET_BIG_ENDIAN)
  3539. - LIBNET_CONFIG_DEFINES="$LIBNET_CONFIG_DEFINES -DLIBNET_BIG_ENDIAN"
  3540. - elif test $ac_cv_libnet_endianess = lil ; then
  3541. - AC_DEFINE(LIBNET_LIL_ENDIAN)
  3542. - LIBNET_CONFIG_DEFINES="$LIBNET_CONFIG_DEFINES -DLIBNET_LIL_ENDIAN"
  3543. - fi
  3544. - ])
  3545. +case $host_os in
  3546. +aix4* | aix5*)
  3547. + lt_cv_deplibs_check_method=pass_all
  3548. + ;;
  3549. +
  3550. +beos*)
  3551. + lt_cv_deplibs_check_method=pass_all
  3552. + ;;
  3553. +
  3554. +bsdi4*)
  3555. + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)'
  3556. + lt_cv_file_magic_cmd='/usr/bin/file -L'
  3557. + lt_cv_file_magic_test_file=/shlib/libc.so
  3558. + ;;
  3559. +
  3560. +cygwin* | mingw* | pw32*)
  3561. + lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
  3562. + lt_cv_file_magic_cmd='$OBJDUMP -f'
  3563. + ;;
  3564. +
  3565. +darwin* | rhapsody*)
  3566. + lt_cv_deplibs_check_method='file_magic Mach-O dynamically linked shared library'
  3567. + lt_cv_file_magic_cmd='/usr/bin/file -L'
  3568. + case "$host_os" in
  3569. + rhapsody* | darwin1.[[012]])
  3570. + lt_cv_file_magic_test_file=`echo /System/Library/Frameworks/System.framework/Versions/*/System | head -1`
  3571. + ;;
  3572. + *) # Darwin 1.3 on
  3573. + lt_cv_file_magic_test_file='/usr/lib/libSystem.dylib'
  3574. + ;;
  3575. + esac
  3576. + ;;
  3577. +
  3578. +freebsd*)
  3579. + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  3580. + case $host_cpu in
  3581. + i*86 )
  3582. + # Not sure whether the presence of OpenBSD here was a mistake.
  3583. + # Let's accept both of them until this is cleared up.
  3584. + lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD)/i[[3-9]]86 (compact )?demand paged shared library'
  3585. + lt_cv_file_magic_cmd=/usr/bin/file
  3586. + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
  3587. + ;;
  3588. + esac
  3589. + else
  3590. + lt_cv_deplibs_check_method=pass_all
  3591. + fi
  3592. + ;;
  3593. +
  3594. +gnu*)
  3595. + lt_cv_deplibs_check_method=pass_all
  3596. + ;;
  3597. +
  3598. +hpux10.20*|hpux11*)
  3599. + lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library'
  3600. + lt_cv_file_magic_cmd=/usr/bin/file
  3601. + lt_cv_file_magic_test_file=/usr/lib/libc.sl
  3602. + ;;
  3603. +
  3604. +irix5* | irix6* | nonstopux*)
  3605. + case $LD in
  3606. + *-32|*"-32 ") libmagic=32-bit;;
  3607. + *-n32|*"-n32 ") libmagic=N32;;
  3608. + *-64|*"-64 ") libmagic=64-bit;;
  3609. + *) libmagic=never-match;;
  3610. + esac
  3611. + lt_cv_deplibs_check_method=pass_all
  3612. + ;;
  3613. +
  3614. +# This must be Linux ELF.
  3615. +linux-gnu*)
  3616. + lt_cv_deplibs_check_method=pass_all
  3617. + ;;
  3618. +
  3619. +netbsd*)
  3620. + if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
  3621. + lt_cv_deplibs_check_method='match_pattern /lib[[^/\.]]+\.so\.[[0-9]]+\.[[0-9]]+$'
  3622. + else
  3623. + lt_cv_deplibs_check_method='match_pattern /lib[[^/\.]]+\.so$'
  3624. + fi
  3625. + ;;
  3626. +
  3627. +newos6*)
  3628. + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)'
  3629. + lt_cv_file_magic_cmd=/usr/bin/file
  3630. + lt_cv_file_magic_test_file=/usr/lib/libnls.so
  3631. + ;;
  3632. +
  3633. +openbsd*)
  3634. + lt_cv_file_magic_cmd=/usr/bin/file
  3635. + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
  3636. + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
  3637. + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB shared object'
  3638. + else
  3639. + lt_cv_deplibs_check_method='file_magic OpenBSD.* shared library'
  3640. + fi
  3641. + ;;
  3642. +
  3643. +osf3* | osf4* | osf5*)
  3644. + lt_cv_deplibs_check_method=pass_all
  3645. + ;;
  3646. +
  3647. +sco3.2v5*)
  3648. + lt_cv_deplibs_check_method=pass_all
  3649. + ;;
  3650. +
  3651. +solaris*)
  3652. + lt_cv_deplibs_check_method=pass_all
  3653. + ;;
  3654. +
  3655. +sysv5uw[[78]]* | sysv4*uw2*)
  3656. + lt_cv_deplibs_check_method=pass_all
  3657. + ;;
  3658. +
  3659. +sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
  3660. + case $host_vendor in
  3661. + motorola)
  3662. + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
  3663. + lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
  3664. + ;;
  3665. + ncr)
  3666. + lt_cv_deplibs_check_method=pass_all
  3667. + ;;
  3668. + sequent)
  3669. + lt_cv_file_magic_cmd='/bin/file'
  3670. + lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
  3671. + ;;
  3672. + sni)
  3673. + lt_cv_file_magic_cmd='/bin/file'
  3674. + lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib"
  3675. + lt_cv_file_magic_test_file=/lib/libc.so
  3676. + ;;
  3677. + siemens)
  3678. + lt_cv_deplibs_check_method=pass_all
  3679. + ;;
  3680. + esac
  3681. + ;;
  3682. +esac
  3683. +])
  3684. +file_magic_cmd=$lt_cv_file_magic_cmd
  3685. +deplibs_check_method=$lt_cv_deplibs_check_method
  3686. +])
  3687. +
  3688. +# AC_PROG_NM - find the path to a BSD-compatible name lister
  3689. +AC_DEFUN([AC_PROG_NM],
  3690. +[AC_REQUIRE([_LT_AC_LIBTOOL_SYS_PATH_SEPARATOR])dnl
  3691. +AC_MSG_CHECKING([for BSD-compatible nm])
  3692. +AC_CACHE_VAL(lt_cv_path_NM,
  3693. +[if test -n "$NM"; then
  3694. + # Let the user override the test.
  3695. + lt_cv_path_NM="$NM"
  3696. +else
  3697. + IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
  3698. + for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
  3699. + test -z "$ac_dir" && ac_dir=.
  3700. + tmp_nm=$ac_dir/${ac_tool_prefix}nm
  3701. + if test -f $tmp_nm || test -f $tmp_nm$ac_exeext ; then
  3702. + # Check to see if the nm accepts a BSD-compat flag.
  3703. + # Adding the `sed 1q' prevents false positives on HP-UX, which says:
  3704. + # nm: unknown option "B" ignored
  3705. + # Tru64's nm complains that /dev/null is an invalid object file
  3706. + if ($tmp_nm -B /dev/null 2>&1 | sed '1q'; exit 0) | egrep '(/dev/null|Invalid file or object type)' >/dev/null; then
  3707. + lt_cv_path_NM="$tmp_nm -B"
  3708. + break
  3709. + elif ($tmp_nm -p /dev/null 2>&1 | sed '1q'; exit 0) | egrep /dev/null >/dev/null; then
  3710. + lt_cv_path_NM="$tmp_nm -p"
  3711. + break
  3712. + else
  3713. + lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
  3714. + continue # so that we can try to find one that supports BSD flags
  3715. + fi
  3716. + fi
  3717. + done
  3718. + IFS="$ac_save_ifs"
  3719. + test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
  3720. +fi])
  3721. +NM="$lt_cv_path_NM"
  3722. +AC_MSG_RESULT([$NM])
  3723. +])
  3724. +
  3725. +# AC_CHECK_LIBM - check for math library
  3726. +AC_DEFUN([AC_CHECK_LIBM],
  3727. +[AC_REQUIRE([AC_CANONICAL_HOST])dnl
  3728. +LIBM=
  3729. +case $host in
  3730. +*-*-beos* | *-*-cygwin* | *-*-pw32*)
  3731. + # These system don't have libm
  3732. + ;;
  3733. +*-ncr-sysv4.3*)
  3734. + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw")
  3735. + AC_CHECK_LIB(m, main, LIBM="$LIBM -lm")
  3736. + ;;
  3737. +*)
  3738. + AC_CHECK_LIB(m, main, LIBM="-lm")
  3739. + ;;
  3740. +esac
  3741. +])
  3742. +
  3743. +# AC_LIBLTDL_CONVENIENCE[(dir)] - sets LIBLTDL to the link flags for
  3744. +# the libltdl convenience library and LTDLINCL to the include flags for
  3745. +# the libltdl header and adds --enable-ltdl-convenience to the
  3746. +# configure arguments. Note that LIBLTDL and LTDLINCL are not
  3747. +# AC_SUBSTed, nor is AC_CONFIG_SUBDIRS called. If DIR is not
  3748. +# provided, it is assumed to be `libltdl'. LIBLTDL will be prefixed
  3749. +# with '${top_builddir}/' and LTDLINCL will be prefixed with
  3750. +# '${top_srcdir}/' (note the single quotes!). If your package is not
  3751. +# flat and you're not using automake, define top_builddir and
  3752. +# top_srcdir appropriately in the Makefiles.
  3753. +AC_DEFUN([AC_LIBLTDL_CONVENIENCE],
  3754. +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3755. + case $enable_ltdl_convenience in
  3756. + no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;;
  3757. + "") enable_ltdl_convenience=yes
  3758. + ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;;
  3759. + esac
  3760. + LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la
  3761. + LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
  3762. + # For backwards non-gettext consistent compatibility...
  3763. + INCLTDL="$LTDLINCL"
  3764. +])
  3765. +
  3766. +# AC_LIBLTDL_INSTALLABLE[(dir)] - sets LIBLTDL to the link flags for
  3767. +# the libltdl installable library and LTDLINCL to the include flags for
  3768. +# the libltdl header and adds --enable-ltdl-install to the configure
  3769. +# arguments. Note that LIBLTDL and LTDLINCL are not AC_SUBSTed, nor is
  3770. +# AC_CONFIG_SUBDIRS called. If DIR is not provided and an installed
  3771. +# libltdl is not found, it is assumed to be `libltdl'. LIBLTDL will
  3772. +# be prefixed with '${top_builddir}/' and LTDLINCL will be prefixed
  3773. +# with '${top_srcdir}/' (note the single quotes!). If your package is
  3774. +# not flat and you're not using automake, define top_builddir and
  3775. +# top_srcdir appropriately in the Makefiles.
  3776. +# In the future, this macro may have to be called after AC_PROG_LIBTOOL.
  3777. +AC_DEFUN([AC_LIBLTDL_INSTALLABLE],
  3778. +[AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
  3779. + AC_CHECK_LIB(ltdl, main,
  3780. + [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no],
  3781. + [if test x"$enable_ltdl_install" = xno; then
  3782. + AC_MSG_WARN([libltdl not installed, but installation disabled])
  3783. + else
  3784. + enable_ltdl_install=yes
  3785. + fi
  3786. + ])
  3787. + if test x"$enable_ltdl_install" = x"yes"; then
  3788. + ac_configure_args="$ac_configure_args --enable-ltdl-install"
  3789. + LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la
  3790. + LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl'])
  3791. + else
  3792. + ac_configure_args="$ac_configure_args --enable-ltdl-install=no"
  3793. + LIBLTDL="-lltdl"
  3794. + LTDLINCL=
  3795. + fi
  3796. + # For backwards non-gettext consistent compatibility...
  3797. + INCLTDL="$LTDLINCL"
  3798. +])
  3799. +
  3800. +# old names
  3801. +AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL])
  3802. +AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)])
  3803. +AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)])
  3804. +AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)])
  3805. +AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)])
  3806. +AC_DEFUN([AM_PROG_LD], [AC_PROG_LD])
  3807. +AC_DEFUN([AM_PROG_NM], [AC_PROG_NM])
  3808. +
  3809. +# This is just to silence aclocal about the macro not being used
  3810. +ifelse([AC_DISABLE_FAST_INSTALL])
  3811. +
  3812. +# NOTE: This macro has been submitted for inclusion into #
  3813. +# GNU Autoconf as AC_PROG_SED. When it is available in #
  3814. +# a released version of Autoconf we should remove this #
  3815. +# macro and use it instead. #
  3816. +# LT_AC_PROG_SED
  3817. +# --------------
  3818. +# Check for a fully-functional sed program, that truncates
  3819. +# as few characters as possible. Prefer GNU sed if found.
  3820. +AC_DEFUN([LT_AC_PROG_SED],
  3821. +[AC_MSG_CHECKING([for a sed that does not truncate output])
  3822. +AC_CACHE_VAL(lt_cv_path_SED,
  3823. +[# Loop through the user's path and test for sed and gsed.
  3824. +# Then use that list of sed's as ones to test for truncation.
  3825. +as_executable_p="test -f"
  3826. +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
  3827. +for as_dir in $PATH
  3828. +do
  3829. + IFS=$as_save_IFS
  3830. + test -z "$as_dir" && as_dir=.
  3831. + for ac_prog in sed gsed; do
  3832. + for ac_exec_ext in '' $ac_executable_extensions; do
  3833. + if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
  3834. + _sed_list="$_sed_list $as_dir/$ac_prog$ac_exec_ext"
  3835. + fi
  3836. + done
  3837. + done
  3838. +done
  3839. +
  3840. + # Create a temporary directory, and hook for its removal unless debugging.
  3841. +$debug ||
  3842. +{
  3843. + trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
  3844. + trap '{ (exit 1); exit 1; }' 1 2 13 15
  3845. +}
  3846. +
  3847. +# Create a (secure) tmp directory for tmp files.
  3848. +: ${TMPDIR=/tmp}
  3849. +{
  3850. + tmp=`(umask 077 && mktemp -d -q "$TMPDIR/sedXXXXXX") 2>/dev/null` &&
  3851. + test -n "$tmp" && test -d "$tmp"
  3852. +} ||
  3853. +{
  3854. + tmp=$TMPDIR/sed$$-$RANDOM
  3855. + (umask 077 && mkdir $tmp)
  3856. +} ||
  3857. +{
  3858. + echo "$me: cannot create a temporary directory in $TMPDIR" >&2
  3859. + { (exit 1); exit 1; }
  3860. +}
  3861. + _max=0
  3862. + _count=0
  3863. + # Add /usr/xpg4/bin/sed as it is typically found on Solaris
  3864. + # along with /bin/sed that truncates output.
  3865. + for _sed in $_sed_list /usr/xpg4/bin/sed; do
  3866. + test ! -f ${_sed} && break
  3867. + cat /dev/null > "$tmp/sed.in"
  3868. + _count=0
  3869. + echo ${ECHO_N-$ac_n} "0123456789${ECHO_C-$ac_c}" >"$tmp/sed.in"
  3870. + # Check for GNU sed and select it if it is found.
  3871. + if "${_sed}" --version 2>&1 < /dev/null | egrep '(GNU)' > /dev/null; then
  3872. + lt_cv_path_SED=${_sed}
  3873. + break
  3874. + fi
  3875. + while true; do
  3876. + cat "$tmp/sed.in" "$tmp/sed.in" >"$tmp/sed.tmp"
  3877. + mv "$tmp/sed.tmp" "$tmp/sed.in"
  3878. + cp "$tmp/sed.in" "$tmp/sed.nl"
  3879. + echo >>"$tmp/sed.nl"
  3880. + ${_sed} -e 's/a$//' < "$tmp/sed.nl" >"$tmp/sed.out" || break
  3881. + cmp -s "$tmp/sed.out" "$tmp/sed.nl" || break
  3882. + # 40000 chars as input seems more than enough
  3883. + test $_count -gt 10 && break
  3884. + _count=`expr $_count + 1`
  3885. + if test $_count -gt $_max; then
  3886. + _max=$_count
  3887. + lt_cv_path_SED=$_sed
  3888. + fi
  3889. + done
  3890. + done
  3891. + rm -rf "$tmp"
  3892. +])
  3893. +if test "X$SED" != "X"; then
  3894. + lt_cv_path_SED=$SED
  3895. +else
  3896. + SED=$lt_cv_path_SED
  3897. +fi
  3898. +AC_MSG_RESULT([$SED])
  3899. +])
  3900. +
  3901. +# -*- Autoconf -*-
  3902. +# Copyright (C) 2002, 2003 Free Software Foundation, Inc.
  3903. +# Generated from amversion.in; do not edit by hand.
  3904. +
  3905. +# This program is free software; you can redistribute it and/or modify
  3906. +# it under the terms of the GNU General Public License as published by
  3907. +# the Free Software Foundation; either version 2, or (at your option)
  3908. +# any later version.
  3909. +
  3910. +# This program is distributed in the hope that it will be useful,
  3911. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  3912. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  3913. +# GNU General Public License for more details.
  3914. +
  3915. +# You should have received a copy of the GNU General Public License
  3916. +# along with this program; if not, write to the Free Software
  3917. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  3918. +
  3919. +# AM_AUTOMAKE_VERSION(VERSION)
  3920. +# ----------------------------
  3921. +# Automake X.Y traces this macro to ensure aclocal.m4 has been
  3922. +# generated from the m4 files accompanying Automake X.Y.
  3923. +AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.8"])
  3924. +
  3925. +# AM_SET_CURRENT_AUTOMAKE_VERSION
  3926. +# -------------------------------
  3927. +# Call AM_AUTOMAKE_VERSION so it can be traced.
  3928. +# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
  3929. +AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
  3930. + [AM_AUTOMAKE_VERSION([1.8.5])])
  3931. +
  3932. +# AM_AUX_DIR_EXPAND
  3933. +
  3934. +# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
  3935. +
  3936. +# This program is free software; you can redistribute it and/or modify
  3937. +# it under the terms of the GNU General Public License as published by
  3938. +# the Free Software Foundation; either version 2, or (at your option)
  3939. +# any later version.
  3940. +
  3941. +# This program is distributed in the hope that it will be useful,
  3942. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  3943. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  3944. +# GNU General Public License for more details.
  3945. +
  3946. +# You should have received a copy of the GNU General Public License
  3947. +# along with this program; if not, write to the Free Software
  3948. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  3949. +# 02111-1307, USA.
  3950. +
  3951. +# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
  3952. +# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
  3953. +# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
  3954. +#
  3955. +# Of course, Automake must honor this variable whenever it calls a
  3956. +# tool from the auxiliary directory. The problem is that $srcdir (and
  3957. +# therefore $ac_aux_dir as well) can be either absolute or relative,
  3958. +# depending on how configure is run. This is pretty annoying, since
  3959. +# it makes $ac_aux_dir quite unusable in subdirectories: in the top
  3960. +# source directory, any form will work fine, but in subdirectories a
  3961. +# relative path needs to be adjusted first.
  3962. +#
  3963. +# $ac_aux_dir/missing
  3964. +# fails when called from a subdirectory if $ac_aux_dir is relative
  3965. +# $top_srcdir/$ac_aux_dir/missing
  3966. +# fails if $ac_aux_dir is absolute,
  3967. +# fails when called from a subdirectory in a VPATH build with
  3968. +# a relative $ac_aux_dir
  3969. +#
  3970. +# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
  3971. +# are both prefixed by $srcdir. In an in-source build this is usually
  3972. +# harmless because $srcdir is `.', but things will broke when you
  3973. +# start a VPATH build or use an absolute $srcdir.
  3974. +#
  3975. +# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
  3976. +# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
  3977. +# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
  3978. +# and then we would define $MISSING as
  3979. +# MISSING="\${SHELL} $am_aux_dir/missing"
  3980. +# This will work as long as MISSING is not called from configure, because
  3981. +# unfortunately $(top_srcdir) has no meaning in configure.
  3982. +# However there are other variables, like CC, which are often used in
  3983. +# configure, and could therefore not use this "fixed" $ac_aux_dir.
  3984. +#
  3985. +# Another solution, used here, is to always expand $ac_aux_dir to an
  3986. +# absolute PATH. The drawback is that using absolute paths prevent a
  3987. +# configured tree to be moved without reconfiguration.
  3988. +
  3989. +AC_DEFUN([AM_AUX_DIR_EXPAND],
  3990. +[dnl Rely on autoconf to set up CDPATH properly.
  3991. +AC_PREREQ([2.50])dnl
  3992. +# expand $ac_aux_dir to an absolute path
  3993. +am_aux_dir=`cd $ac_aux_dir && pwd`
  3994. +])
  3995. +
  3996. +# AM_CONDITIONAL -*- Autoconf -*-
  3997. +
  3998. +# Copyright (C) 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
  3999. +
  4000. +# This program is free software; you can redistribute it and/or modify
  4001. +# it under the terms of the GNU General Public License as published by
  4002. +# the Free Software Foundation; either version 2, or (at your option)
  4003. +# any later version.
  4004. +
  4005. +# This program is distributed in the hope that it will be useful,
  4006. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4007. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4008. +# GNU General Public License for more details.
  4009. +
  4010. +# You should have received a copy of the GNU General Public License
  4011. +# along with this program; if not, write to the Free Software
  4012. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4013. +# 02111-1307, USA.
  4014. +
  4015. +# serial 6
  4016. +
  4017. +# AM_CONDITIONAL(NAME, SHELL-CONDITION)
  4018. +# -------------------------------------
  4019. +# Define a conditional.
  4020. +AC_DEFUN([AM_CONDITIONAL],
  4021. +[AC_PREREQ(2.52)dnl
  4022. + ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
  4023. + [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
  4024. +AC_SUBST([$1_TRUE])
  4025. +AC_SUBST([$1_FALSE])
  4026. +if $2; then
  4027. + $1_TRUE=
  4028. + $1_FALSE='#'
  4029. +else
  4030. + $1_TRUE='#'
  4031. + $1_FALSE=
  4032. +fi
  4033. +AC_CONFIG_COMMANDS_PRE(
  4034. +[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
  4035. + AC_MSG_ERROR([conditional "$1" was never defined.
  4036. +Usually this means the macro was only invoked conditionally.])
  4037. +fi])])
  4038. +
  4039. +# serial 7 -*- Autoconf -*-
  4040. +
  4041. +# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004
  4042. +# Free Software Foundation, Inc.
  4043. +
  4044. +# This program is free software; you can redistribute it and/or modify
  4045. +# it under the terms of the GNU General Public License as published by
  4046. +# the Free Software Foundation; either version 2, or (at your option)
  4047. +# any later version.
  4048. +
  4049. +# This program is distributed in the hope that it will be useful,
  4050. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4051. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4052. +# GNU General Public License for more details.
  4053. +
  4054. +# You should have received a copy of the GNU General Public License
  4055. +# along with this program; if not, write to the Free Software
  4056. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4057. +# 02111-1307, USA.
  4058. +
  4059. +
  4060. +# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
  4061. +# written in clear, in which case automake, when reading aclocal.m4,
  4062. +# will think it sees a *use*, and therefore will trigger all it's
  4063. +# C support machinery. Also note that it means that autoscan, seeing
  4064. +# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
  4065. +
  4066. +
  4067. +
  4068. +# _AM_DEPENDENCIES(NAME)
  4069. +# ----------------------
  4070. +# See how the compiler implements dependency checking.
  4071. +# NAME is "CC", "CXX", "GCJ", or "OBJC".
  4072. +# We try a few techniques and use that to set a single cache variable.
  4073. +#
  4074. +# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
  4075. +# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
  4076. +# dependency, and given that the user is not expected to run this macro,
  4077. +# just rely on AC_PROG_CC.
  4078. +AC_DEFUN([_AM_DEPENDENCIES],
  4079. +[AC_REQUIRE([AM_SET_DEPDIR])dnl
  4080. +AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
  4081. +AC_REQUIRE([AM_MAKE_INCLUDE])dnl
  4082. +AC_REQUIRE([AM_DEP_TRACK])dnl
  4083. +
  4084. +ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
  4085. + [$1], CXX, [depcc="$CXX" am_compiler_list=],
  4086. + [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
  4087. + [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
  4088. + [depcc="$$1" am_compiler_list=])
  4089. +
  4090. +AC_CACHE_CHECK([dependency style of $depcc],
  4091. + [am_cv_$1_dependencies_compiler_type],
  4092. +[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  4093. + # We make a subdir and do the tests there. Otherwise we can end up
  4094. + # making bogus files that we don't know about and never remove. For
  4095. + # instance it was reported that on HP-UX the gcc test will end up
  4096. + # making a dummy file named `D' -- because `-MD' means `put the output
  4097. + # in D'.
  4098. + mkdir conftest.dir
  4099. + # Copy depcomp to subdir because otherwise we won't find it if we're
  4100. + # using a relative directory.
  4101. + cp "$am_depcomp" conftest.dir
  4102. + cd conftest.dir
  4103. + # We will build objects and dependencies in a subdirectory because
  4104. + # it helps to detect inapplicable dependency modes. For instance
  4105. + # both Tru64's cc and ICC support -MD to output dependencies as a
  4106. + # side effect of compilation, but ICC will put the dependencies in
  4107. + # the current directory while Tru64 will put them in the object
  4108. + # directory.
  4109. + mkdir sub
  4110. +
  4111. + am_cv_$1_dependencies_compiler_type=none
  4112. + if test "$am_compiler_list" = ""; then
  4113. + am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
  4114. + fi
  4115. + for depmode in $am_compiler_list; do
  4116. + # Setup a source with many dependencies, because some compilers
  4117. + # like to wrap large dependency lists on column 80 (with \), and
  4118. + # we should not choose a depcomp mode which is confused by this.
  4119. + #
  4120. + # We need to recreate these files for each test, as the compiler may
  4121. + # overwrite some of them when testing with obscure command lines.
  4122. + # This happens at least with the AIX C compiler.
  4123. + : > sub/conftest.c
  4124. + for i in 1 2 3 4 5 6; do
  4125. + echo '#include "conftst'$i'.h"' >> sub/conftest.c
  4126. + # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
  4127. + # Solaris 8's {/usr,}/bin/sh.
  4128. + touch sub/conftst$i.h
  4129. + done
  4130. + echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
  4131. +
  4132. + case $depmode in
  4133. + nosideeffect)
  4134. + # after this tag, mechanisms are not by side-effect, so they'll
  4135. + # only be used when explicitly requested
  4136. + if test "x$enable_dependency_tracking" = xyes; then
  4137. + continue
  4138. + else
  4139. + break
  4140. + fi
  4141. + ;;
  4142. + none) break ;;
  4143. + esac
  4144. + # We check with `-c' and `-o' for the sake of the "dashmstdout"
  4145. + # mode. It turns out that the SunPro C++ compiler does not properly
  4146. + # handle `-M -o', and we need to detect this.
  4147. + if depmode=$depmode \
  4148. + source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
  4149. + depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
  4150. + $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
  4151. + >/dev/null 2>conftest.err &&
  4152. + grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
  4153. + grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
  4154. + ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
  4155. + # icc doesn't choke on unknown options, it will just issue warnings
  4156. + # or remarks (even with -Werror). So we grep stderr for any message
  4157. + # that says an option was ignored or not supported.
  4158. + # When given -MP, icc 7.0 and 7.1 complain thusly:
  4159. + # icc: Command line warning: ignoring option '-M'; no argument required
  4160. + # The diagnosis changed in icc 8.0:
  4161. + # icc: Command line remark: option '-MP' not supported
  4162. + if (grep 'ignoring option' conftest.err ||
  4163. + grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
  4164. + am_cv_$1_dependencies_compiler_type=$depmode
  4165. + break
  4166. + fi
  4167. + fi
  4168. + done
  4169. +
  4170. + cd ..
  4171. + rm -rf conftest.dir
  4172. +else
  4173. + am_cv_$1_dependencies_compiler_type=none
  4174. +fi
  4175. +])
  4176. +AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
  4177. +AM_CONDITIONAL([am__fastdep$1], [
  4178. + test "x$enable_dependency_tracking" != xno \
  4179. + && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
  4180. +])
  4181. +
  4182. +
  4183. +# AM_SET_DEPDIR
  4184. +# -------------
  4185. +# Choose a directory name for dependency files.
  4186. +# This macro is AC_REQUIREd in _AM_DEPENDENCIES
  4187. +AC_DEFUN([AM_SET_DEPDIR],
  4188. +[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  4189. +AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
  4190. +])
  4191. +
  4192. +
  4193. +# AM_DEP_TRACK
  4194. +# ------------
  4195. +AC_DEFUN([AM_DEP_TRACK],
  4196. +[AC_ARG_ENABLE(dependency-tracking,
  4197. +[ --disable-dependency-tracking speeds up one-time build
  4198. + --enable-dependency-tracking do not reject slow dependency extractors])
  4199. +if test "x$enable_dependency_tracking" != xno; then
  4200. + am_depcomp="$ac_aux_dir/depcomp"
  4201. + AMDEPBACKSLASH='\'
  4202. +fi
  4203. +AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
  4204. +AC_SUBST([AMDEPBACKSLASH])
  4205. +])
  4206. +
  4207. +# Generate code to set up dependency tracking. -*- Autoconf -*-
  4208. +
  4209. +# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
  4210. +
  4211. +# This program is free software; you can redistribute it and/or modify
  4212. +# it under the terms of the GNU General Public License as published by
  4213. +# the Free Software Foundation; either version 2, or (at your option)
  4214. +# any later version.
  4215. +
  4216. +# This program is distributed in the hope that it will be useful,
  4217. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4218. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4219. +# GNU General Public License for more details.
  4220. +
  4221. +# You should have received a copy of the GNU General Public License
  4222. +# along with this program; if not, write to the Free Software
  4223. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4224. +# 02111-1307, USA.
  4225. +
  4226. +#serial 2
  4227. +
  4228. +# _AM_OUTPUT_DEPENDENCY_COMMANDS
  4229. +# ------------------------------
  4230. +AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
  4231. +[for mf in $CONFIG_FILES; do
  4232. + # Strip MF so we end up with the name of the file.
  4233. + mf=`echo "$mf" | sed -e 's/:.*$//'`
  4234. + # Check whether this is an Automake generated Makefile or not.
  4235. + # We used to match only the files named `Makefile.in', but
  4236. + # some people rename them; so instead we look at the file content.
  4237. + # Grep'ing the first line is not enough: some people post-process
  4238. + # each Makefile.in and add a new line on top of each file to say so.
  4239. + # So let's grep whole file.
  4240. + if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
  4241. + dirpart=`AS_DIRNAME("$mf")`
  4242. + else
  4243. + continue
  4244. + fi
  4245. + grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
  4246. + # Extract the definition of DEP_FILES from the Makefile without
  4247. + # running `make'.
  4248. + DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
  4249. + test -z "$DEPDIR" && continue
  4250. + # When using ansi2knr, U may be empty or an underscore; expand it
  4251. + U=`sed -n 's/^U = //p' < "$mf"`
  4252. + test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
  4253. + # We invoke sed twice because it is the simplest approach to
  4254. + # changing $(DEPDIR) to its actual value in the expansion.
  4255. + for file in `sed -n '
  4256. + /^DEP_FILES = .*\\\\$/ {
  4257. + s/^DEP_FILES = //
  4258. + :loop
  4259. + s/\\\\$//
  4260. + p
  4261. + n
  4262. + /\\\\$/ b loop
  4263. + p
  4264. + }
  4265. + /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
  4266. + sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
  4267. + # Make sure the directory exists.
  4268. + test -f "$dirpart/$file" && continue
  4269. + fdir=`AS_DIRNAME(["$file"])`
  4270. + AS_MKDIR_P([$dirpart/$fdir])
  4271. + # echo "creating $dirpart/$file"
  4272. + echo '# dummy' > "$dirpart/$file"
  4273. + done
  4274. +done
  4275. +])# _AM_OUTPUT_DEPENDENCY_COMMANDS
  4276. +
  4277. +
  4278. +# AM_OUTPUT_DEPENDENCY_COMMANDS
  4279. +# -----------------------------
  4280. +# This macro should only be invoked once -- use via AC_REQUIRE.
  4281. +#
  4282. +# This code is only required when automatic dependency tracking
  4283. +# is enabled. FIXME. This creates each `.P' file that we will
  4284. +# need in order to bootstrap the dependency handling code.
  4285. +AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
  4286. +[AC_CONFIG_COMMANDS([depfiles],
  4287. + [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
  4288. + [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
  4289. +])
  4290. +
  4291. +# Do all the work for Automake. -*- Autoconf -*-
  4292. +
  4293. +# This macro actually does too much some checks are only needed if
  4294. +# your package does certain things. But this isn't really a big deal.
  4295. +
  4296. +# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
  4297. +# Free Software Foundation, Inc.
  4298. +
  4299. +# This program is free software; you can redistribute it and/or modify
  4300. +# it under the terms of the GNU General Public License as published by
  4301. +# the Free Software Foundation; either version 2, or (at your option)
  4302. +# any later version.
  4303. +
  4304. +# This program is distributed in the hope that it will be useful,
  4305. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4306. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4307. +# GNU General Public License for more details.
  4308. +
  4309. +# You should have received a copy of the GNU General Public License
  4310. +# along with this program; if not, write to the Free Software
  4311. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4312. +# 02111-1307, USA.
  4313. +
  4314. +# serial 11
  4315. +
  4316. +# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
  4317. +# AM_INIT_AUTOMAKE([OPTIONS])
  4318. +# -----------------------------------------------
  4319. +# The call with PACKAGE and VERSION arguments is the old style
  4320. +# call (pre autoconf-2.50), which is being phased out. PACKAGE
  4321. +# and VERSION should now be passed to AC_INIT and removed from
  4322. +# the call to AM_INIT_AUTOMAKE.
  4323. +# We support both call styles for the transition. After
  4324. +# the next Automake release, Autoconf can make the AC_INIT
  4325. +# arguments mandatory, and then we can depend on a new Autoconf
  4326. +# release and drop the old call support.
  4327. +AC_DEFUN([AM_INIT_AUTOMAKE],
  4328. +[AC_PREREQ([2.58])dnl
  4329. +dnl Autoconf wants to disallow AM_ names. We explicitly allow
  4330. +dnl the ones we care about.
  4331. +m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
  4332. +AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
  4333. +AC_REQUIRE([AC_PROG_INSTALL])dnl
  4334. +# test to see if srcdir already configured
  4335. +if test "`cd $srcdir && pwd`" != "`pwd`" &&
  4336. + test -f $srcdir/config.status; then
  4337. + AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
  4338. +fi
  4339. +
  4340. +# test whether we have cygpath
  4341. +if test -z "$CYGPATH_W"; then
  4342. + if (cygpath --version) >/dev/null 2>/dev/null; then
  4343. + CYGPATH_W='cygpath -w'
  4344. + else
  4345. + CYGPATH_W=echo
  4346. + fi
  4347. +fi
  4348. +AC_SUBST([CYGPATH_W])
  4349. +
  4350. +# Define the identity of the package.
  4351. +dnl Distinguish between old-style and new-style calls.
  4352. +m4_ifval([$2],
  4353. +[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
  4354. + AC_SUBST([PACKAGE], [$1])dnl
  4355. + AC_SUBST([VERSION], [$2])],
  4356. +[_AM_SET_OPTIONS([$1])dnl
  4357. + AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
  4358. + AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
  4359. +
  4360. +_AM_IF_OPTION([no-define],,
  4361. +[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
  4362. + AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
  4363. +
  4364. +# Some tools Automake needs.
  4365. +AC_REQUIRE([AM_SANITY_CHECK])dnl
  4366. +AC_REQUIRE([AC_ARG_PROGRAM])dnl
  4367. +AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
  4368. +AM_MISSING_PROG(AUTOCONF, autoconf)
  4369. +AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
  4370. +AM_MISSING_PROG(AUTOHEADER, autoheader)
  4371. +AM_MISSING_PROG(MAKEINFO, makeinfo)
  4372. +AM_MISSING_PROG(AMTAR, tar)
  4373. +AM_PROG_INSTALL_SH
  4374. +AM_PROG_INSTALL_STRIP
  4375. +AC_REQUIRE([AM_PROG_MKDIR_P])dnl
  4376. +# We need awk for the "check" target. The system "awk" is bad on
  4377. +# some platforms.
  4378. +AC_REQUIRE([AC_PROG_AWK])dnl
  4379. +AC_REQUIRE([AC_PROG_MAKE_SET])dnl
  4380. +AC_REQUIRE([AM_SET_LEADING_DOT])dnl
  4381. +
  4382. +_AM_IF_OPTION([no-dependencies],,
  4383. +[AC_PROVIDE_IFELSE([AC_PROG_CC],
  4384. + [_AM_DEPENDENCIES(CC)],
  4385. + [define([AC_PROG_CC],
  4386. + defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
  4387. +AC_PROVIDE_IFELSE([AC_PROG_CXX],
  4388. + [_AM_DEPENDENCIES(CXX)],
  4389. + [define([AC_PROG_CXX],
  4390. + defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
  4391. +])
  4392. +])
  4393. +
  4394. +
  4395. +# When config.status generates a header, we must update the stamp-h file.
  4396. +# This file resides in the same directory as the config header
  4397. +# that is generated. The stamp files are numbered to have different names.
  4398. +
  4399. +# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
  4400. +# loop where config.status creates the headers, so we can generate
  4401. +# our stamp files there.
  4402. +AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
  4403. +[# Compute $1's index in $config_headers.
  4404. +_am_stamp_count=1
  4405. +for _am_header in $config_headers :; do
  4406. + case $_am_header in
  4407. + $1 | $1:* )
  4408. + break ;;
  4409. + * )
  4410. + _am_stamp_count=`expr $_am_stamp_count + 1` ;;
  4411. + esac
  4412. +done
  4413. +echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
  4414. +
  4415. +# AM_PROG_INSTALL_SH
  4416. +# ------------------
  4417. +# Define $install_sh.
  4418. +
  4419. +# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
  4420. +
  4421. +# This program is free software; you can redistribute it and/or modify
  4422. +# it under the terms of the GNU General Public License as published by
  4423. +# the Free Software Foundation; either version 2, or (at your option)
  4424. +# any later version.
  4425. +
  4426. +# This program is distributed in the hope that it will be useful,
  4427. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4428. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4429. +# GNU General Public License for more details.
  4430. +
  4431. +# You should have received a copy of the GNU General Public License
  4432. +# along with this program; if not, write to the Free Software
  4433. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4434. +# 02111-1307, USA.
  4435. +
  4436. +AC_DEFUN([AM_PROG_INSTALL_SH],
  4437. +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  4438. +install_sh=${install_sh-"$am_aux_dir/install-sh"}
  4439. +AC_SUBST(install_sh)])
  4440. +
  4441. +# -*- Autoconf -*-
  4442. +# Copyright (C) 2003 Free Software Foundation, Inc.
  4443. +
  4444. +# This program is free software; you can redistribute it and/or modify
  4445. +# it under the terms of the GNU General Public License as published by
  4446. +# the Free Software Foundation; either version 2, or (at your option)
  4447. +# any later version.
  4448. +
  4449. +# This program is distributed in the hope that it will be useful,
  4450. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4451. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4452. +# GNU General Public License for more details.
  4453. +
  4454. +# You should have received a copy of the GNU General Public License
  4455. +# along with this program; if not, write to the Free Software
  4456. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4457. +# 02111-1307, USA.
  4458. +
  4459. +# serial 1
  4460. +
  4461. +# Check whether the underlying file-system supports filenames
  4462. +# with a leading dot. For instance MS-DOS doesn't.
  4463. +AC_DEFUN([AM_SET_LEADING_DOT],
  4464. +[rm -rf .tst 2>/dev/null
  4465. +mkdir .tst 2>/dev/null
  4466. +if test -d .tst; then
  4467. + am__leading_dot=.
  4468. +else
  4469. + am__leading_dot=_
  4470. +fi
  4471. +rmdir .tst 2>/dev/null
  4472. +AC_SUBST([am__leading_dot])])
  4473. +
  4474. +# Check to see how 'make' treats includes. -*- Autoconf -*-
  4475. +
  4476. +# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
  4477. +
  4478. +# This program is free software; you can redistribute it and/or modify
  4479. +# it under the terms of the GNU General Public License as published by
  4480. +# the Free Software Foundation; either version 2, or (at your option)
  4481. +# any later version.
  4482. +
  4483. +# This program is distributed in the hope that it will be useful,
  4484. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4485. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4486. +# GNU General Public License for more details.
  4487. +
  4488. +# You should have received a copy of the GNU General Public License
  4489. +# along with this program; if not, write to the Free Software
  4490. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4491. +# 02111-1307, USA.
  4492. +
  4493. +# serial 2
  4494. +
  4495. +# AM_MAKE_INCLUDE()
  4496. +# -----------------
  4497. +# Check to see how make treats includes.
  4498. +AC_DEFUN([AM_MAKE_INCLUDE],
  4499. +[am_make=${MAKE-make}
  4500. +cat > confinc << 'END'
  4501. +am__doit:
  4502. + @echo done
  4503. +.PHONY: am__doit
  4504. +END
  4505. +# If we don't find an include directive, just comment out the code.
  4506. +AC_MSG_CHECKING([for style of include used by $am_make])
  4507. +am__include="#"
  4508. +am__quote=
  4509. +_am_result=none
  4510. +# First try GNU make style include.
  4511. +echo "include confinc" > confmf
  4512. +# We grep out `Entering directory' and `Leaving directory'
  4513. +# messages which can occur if `w' ends up in MAKEFLAGS.
  4514. +# In particular we don't look at `^make:' because GNU make might
  4515. +# be invoked under some other name (usually "gmake"), in which
  4516. +# case it prints its new name instead of `make'.
  4517. +if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
  4518. + am__include=include
  4519. + am__quote=
  4520. + _am_result=GNU
  4521. +fi
  4522. +# Now try BSD make style include.
  4523. +if test "$am__include" = "#"; then
  4524. + echo '.include "confinc"' > confmf
  4525. + if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
  4526. + am__include=.include
  4527. + am__quote="\""
  4528. + _am_result=BSD
  4529. + fi
  4530. +fi
  4531. +AC_SUBST([am__include])
  4532. +AC_SUBST([am__quote])
  4533. +AC_MSG_RESULT([$_am_result])
  4534. +rm -f confinc confmf
  4535. +])
  4536. +
  4537. +# -*- Autoconf -*-
  4538. +
  4539. +
  4540. +# Copyright (C) 1997, 1999, 2000, 2001, 2003 Free Software Foundation, Inc.
  4541. +
  4542. +# This program is free software; you can redistribute it and/or modify
  4543. +# it under the terms of the GNU General Public License as published by
  4544. +# the Free Software Foundation; either version 2, or (at your option)
  4545. +# any later version.
  4546. +
  4547. +# This program is distributed in the hope that it will be useful,
  4548. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4549. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4550. +# GNU General Public License for more details.
  4551. +
  4552. +# You should have received a copy of the GNU General Public License
  4553. +# along with this program; if not, write to the Free Software
  4554. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4555. +# 02111-1307, USA.
  4556. +
  4557. +# serial 3
  4558. +
  4559. +# AM_MISSING_PROG(NAME, PROGRAM)
  4560. +# ------------------------------
  4561. +AC_DEFUN([AM_MISSING_PROG],
  4562. +[AC_REQUIRE([AM_MISSING_HAS_RUN])
  4563. +$1=${$1-"${am_missing_run}$2"}
  4564. +AC_SUBST($1)])
  4565. +
  4566. +
  4567. +# AM_MISSING_HAS_RUN
  4568. +# ------------------
  4569. +# Define MISSING if not defined so far and test if it supports --run.
  4570. +# If it does, set am_missing_run to use it, otherwise, to nothing.
  4571. +AC_DEFUN([AM_MISSING_HAS_RUN],
  4572. +[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
  4573. +test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
  4574. +# Use eval to expand $SHELL
  4575. +if eval "$MISSING --run true"; then
  4576. + am_missing_run="$MISSING --run "
  4577. +else
  4578. + am_missing_run=
  4579. + AC_MSG_WARN([`missing' script is too old or missing])
  4580. +fi
  4581. +])
  4582. +
  4583. +# AM_PROG_MKDIR_P
  4584. +# ---------------
  4585. +# Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise.
  4586. +
  4587. +# Copyright (C) 2003, 2004 Free Software Foundation, Inc.
  4588. +
  4589. +# This program is free software; you can redistribute it and/or modify
  4590. +# it under the terms of the GNU General Public License as published by
  4591. +# the Free Software Foundation; either version 2, or (at your option)
  4592. +# any later version.
  4593. +
  4594. +# This program is distributed in the hope that it will be useful,
  4595. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4596. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4597. +# GNU General Public License for more details.
  4598. +
  4599. +# You should have received a copy of the GNU General Public License
  4600. +# along with this program; if not, write to the Free Software
  4601. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4602. +# 02111-1307, USA.
  4603. +
  4604. +# Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories
  4605. +# created by `make install' are always world readable, even if the
  4606. +# installer happens to have an overly restrictive umask (e.g. 077).
  4607. +# This was a mistake. There are at least two reasons why we must not
  4608. +# use `-m 0755':
  4609. +# - it causes special bits like SGID to be ignored,
  4610. +# - it may be too restrictive (some setups expect 775 directories).
  4611. +#
  4612. +# Do not use -m 0755 and let people choose whatever they expect by
  4613. +# setting umask.
  4614. +#
  4615. +# We cannot accept any implementation of `mkdir' that recognizes `-p'.
  4616. +# Some implementations (such as Solaris 8's) are not thread-safe: if a
  4617. +# parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c'
  4618. +# concurrently, both version can detect that a/ is missing, but only
  4619. +# one can create it and the other will error out. Consequently we
  4620. +# restrict ourselves to GNU make (using the --version option ensures
  4621. +# this.)
  4622. +AC_DEFUN([AM_PROG_MKDIR_P],
  4623. +[if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
  4624. + # Keeping the `.' argument allows $(mkdir_p) to be used without
  4625. + # argument. Indeed, we sometimes output rules like
  4626. + # $(mkdir_p) $(somedir)
  4627. + # where $(somedir) is conditionally defined.
  4628. + # (`test -n '$(somedir)' && $(mkdir_p) $(somedir)' is a more
  4629. + # expensive solution, as it forces Make to start a sub-shell.)
  4630. + mkdir_p='mkdir -p -- .'
  4631. +else
  4632. + # On NextStep and OpenStep, the `mkdir' command does not
  4633. + # recognize any option. It will interpret all options as
  4634. + # directories to create, and then abort because `.' already
  4635. + # exists.
  4636. + for d in ./-p ./--version;
  4637. + do
  4638. + test -d $d && rmdir $d
  4639. + done
  4640. + # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
  4641. + if test -f "$ac_aux_dir/mkinstalldirs"; then
  4642. + mkdir_p='$(mkinstalldirs)'
  4643. + else
  4644. + mkdir_p='$(install_sh) -d'
  4645. + fi
  4646. +fi
  4647. +AC_SUBST([mkdir_p])])
  4648. +
  4649. +# Helper functions for option handling. -*- Autoconf -*-
  4650. +
  4651. +# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
  4652. +
  4653. +# This program is free software; you can redistribute it and/or modify
  4654. +# it under the terms of the GNU General Public License as published by
  4655. +# the Free Software Foundation; either version 2, or (at your option)
  4656. +# any later version.
  4657. +
  4658. +# This program is distributed in the hope that it will be useful,
  4659. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4660. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4661. +# GNU General Public License for more details.
  4662. +
  4663. +# You should have received a copy of the GNU General Public License
  4664. +# along with this program; if not, write to the Free Software
  4665. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4666. +# 02111-1307, USA.
  4667. +
  4668. +# serial 2
  4669. +
  4670. +# _AM_MANGLE_OPTION(NAME)
  4671. +# -----------------------
  4672. +AC_DEFUN([_AM_MANGLE_OPTION],
  4673. +[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
  4674. +
  4675. +# _AM_SET_OPTION(NAME)
  4676. +# ------------------------------
  4677. +# Set option NAME. Presently that only means defining a flag for this option.
  4678. +AC_DEFUN([_AM_SET_OPTION],
  4679. +[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
  4680. +
  4681. +# _AM_SET_OPTIONS(OPTIONS)
  4682. +# ----------------------------------
  4683. +# OPTIONS is a space-separated list of Automake options.
  4684. +AC_DEFUN([_AM_SET_OPTIONS],
  4685. +[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
  4686. +
  4687. +# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
  4688. +# -------------------------------------------
  4689. +# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
  4690. +AC_DEFUN([_AM_IF_OPTION],
  4691. +[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
  4692. +
  4693. +#
  4694. +# Check to make sure that the build environment is sane.
  4695. +#
  4696. +
  4697. +# Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
  4698. +
  4699. +# This program is free software; you can redistribute it and/or modify
  4700. +# it under the terms of the GNU General Public License as published by
  4701. +# the Free Software Foundation; either version 2, or (at your option)
  4702. +# any later version.
  4703. +
  4704. +# This program is distributed in the hope that it will be useful,
  4705. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4706. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4707. +# GNU General Public License for more details.
  4708. +
  4709. +# You should have received a copy of the GNU General Public License
  4710. +# along with this program; if not, write to the Free Software
  4711. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4712. +# 02111-1307, USA.
  4713. +
  4714. +# serial 3
  4715. +
  4716. +# AM_SANITY_CHECK
  4717. +# ---------------
  4718. +AC_DEFUN([AM_SANITY_CHECK],
  4719. +[AC_MSG_CHECKING([whether build environment is sane])
  4720. +# Just in case
  4721. +sleep 1
  4722. +echo timestamp > conftest.file
  4723. +# Do `set' in a subshell so we don't clobber the current shell's
  4724. +# arguments. Must try -L first in case configure is actually a
  4725. +# symlink; some systems play weird games with the mod time of symlinks
  4726. +# (eg FreeBSD returns the mod time of the symlink's containing
  4727. +# directory).
  4728. +if (
  4729. + set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
  4730. + if test "$[*]" = "X"; then
  4731. + # -L didn't work.
  4732. + set X `ls -t $srcdir/configure conftest.file`
  4733. + fi
  4734. + rm -f conftest.file
  4735. + if test "$[*]" != "X $srcdir/configure conftest.file" \
  4736. + && test "$[*]" != "X conftest.file $srcdir/configure"; then
  4737. +
  4738. + # If neither matched, then we have a broken ls. This can happen
  4739. + # if, for instance, CONFIG_SHELL is bash and it inherits a
  4740. + # broken ls alias from the environment. This has actually
  4741. + # happened. Such a system could not be considered "sane".
  4742. + AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken
  4743. +alias in your environment])
  4744. + fi
  4745. +
  4746. + test "$[2]" = conftest.file
  4747. + )
  4748. +then
  4749. + # Ok.
  4750. + :
  4751. +else
  4752. + AC_MSG_ERROR([newly created file is older than distributed files!
  4753. +Check your system clock])
  4754. +fi
  4755. +AC_MSG_RESULT(yes)])
  4756. +
  4757. +# AM_PROG_INSTALL_STRIP
  4758. +
  4759. +# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
  4760. +
  4761. +# This program is free software; you can redistribute it and/or modify
  4762. +# it under the terms of the GNU General Public License as published by
  4763. +# the Free Software Foundation; either version 2, or (at your option)
  4764. +# any later version.
  4765. +
  4766. +# This program is distributed in the hope that it will be useful,
  4767. +# but WITHOUT ANY WARRANTY; without even the implied warranty of
  4768. +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  4769. +# GNU General Public License for more details.
  4770. +
  4771. +# You should have received a copy of the GNU General Public License
  4772. +# along with this program; if not, write to the Free Software
  4773. +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
  4774. +# 02111-1307, USA.
  4775. +
  4776. +# One issue with vendor `install' (even GNU) is that you can't
  4777. +# specify the program used to strip binaries. This is especially
  4778. +# annoying in cross-compiling environments, where the build's strip
  4779. +# is unlikely to handle the host's binaries.
  4780. +# Fortunately install-sh will honor a STRIPPROG variable, so we
  4781. +# always use install-sh in `make install-strip', and initialize
  4782. +# STRIPPROG with the value of the STRIP variable (set by the user).
  4783. +AC_DEFUN([AM_PROG_INSTALL_STRIP],
  4784. +[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
  4785. +# Installed binaries are usually stripped using `strip' when the user
  4786. +# run `make install-strip'. However `strip' might not be the right
  4787. +# tool to use in cross-compilation environments, therefore Automake
  4788. +# will honor the `STRIP' environment variable to overrule this program.
  4789. +dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
  4790. +if test "$cross_compiling" != no; then
  4791. + AC_CHECK_TOOL([STRIP], [strip], :)
  4792. +fi
  4793. +INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
  4794. +AC_SUBST([INSTALL_STRIP_PROGRAM])])
  4795. +
  4796. +m4_include([acinclude.m4])